(C-x means ctrl+x, M-x means alt+x)
The default prefix is C-b. If you (or your muscle memory) prefer C-a, you need to add this to ~/.tmux.conf:
| #!/bin/bash | |
| REQUIRED_ARGS=2 | |
| PULL_DIR="./" | |
| ADB_PATH=`which adb` | |
| if [ $? -ne 0 ] | |
| then | |
| echo "Could not find adb!" | |
| exit 1 | |
| fi; |
| # Move code from one repo to another, preserving commit history | |
| # Source: http://stackoverflow.com/a/17373088/963881 | |
| cd repo2 | |
| git checkout master | |
| git remote add r1remote **url-of-repo1** | |
| git fetch r1remote | |
| git merge r1remote/master | |
| git remote rm r1remote | |
| # Push to master without having to --set-upstream-to first |
| // "License": Public Domain | |
| // I, Mathias Panzenböck, place this file hereby into the public domain. Use it at your own risk for whatever you like. | |
| // In case there are jurisdictions that don't support putting things in the public domain you can also consider it to | |
| // be "dual licensed" under the BSD, MIT and Apache licenses, if you want to. This code is trivial anyway. Consider it | |
| // an example on how to get the endian conversion functions on different platforms. | |
| #ifndef PORTABLE_ENDIAN_H__ | |
| #define PORTABLE_ENDIAN_H__ | |
| #if (defined(_WIN16) || defined(_WIN32) || defined(_WIN64)) && !defined(__WINDOWS__) |
| #!/bin/bash | |
| # From ScalaCourses.com Introduction to Play Framework with Scala course | |
| set -eo pipefail | |
| function help { | |
| echo "Download or update Typesafe Activator on Linux and Cygwin" | |
| echo "Usage: $(basename $0) [options]" | |
| echo "Options are:" |
| #!/bin/bash | |
| # | |
| # template script for generating CentOS container for LXC | |
| # | |
| # | |
| # lxc: linux Container library | |
| # Authors: |
| # (1) mv with regexp | |
| for i in *; do mv -n "$i" "${i/_*dpi*}".png; done; | |
| # (2) Loop over array of strings | |
| declare -a arr=("element1" "element2" "element3") | |
| ## now loop through the above array | |
| for i in "${arr[@]}" | |
| do | |
| echo "$i" |
| # Time functions | |
| import timeit | |
| timeit.timeit(a, number=1) |
| extends cpp | |
| # CUDA | |
| ## CUDA Functions | |
| snippet sync | |
| __syncthreads(); | |
| ${1} | |
| snippet thsync |