As configured in my dotfiles.
start new:
tmux
start new with session name:
| # Path to your oh-my-zsh configuration. | |
| export ZSH=$HOME/.oh-my-zsh | |
| # Set name of the theme to load. | |
| # Look in ~/.oh-my-zsh/themes/ | |
| # Optionally, if you set this to "random", it'll load a random theme each | |
| # time that oh-my-zsh is loaded. | |
| #export ZSH_THEME="robbyrussell" | |
| export ZSH_THEME="zanshin" |
As configured in my dotfiles.
start new:
tmux
start new with session name:
| #!/bin/python | |
| # | |
| # Connects to a Wifi network | |
| # | |
| import os | |
| def commandExists(command): | |
| def canExecute(file): | |
| return os.path.isfile(file) and os.access(file, os.X_OK) |
| ### Sending a file | |
| # BSD nc syntax | |
| cat myDocument.pdf | ssh me.myserver.com nc -l 20000 | |
| # Hobbit nc syntax - try this one if unsure! | |
| cat myDocument.pdf | ssh me.myserver.com nc -l -p 20000 | |
| ### Receiving a file | |
| nc me.myserver.com 20000 > myDocument.pdf |
| #!/usr/local/bin/python | |
| ####################################################### | |
| # Otsu's Method | |
| # Author: Samuel Jackson ([email protected]) | |
| # Date: 21/07/2013 | |
| # Description: Performs Otsu's method of thresholding | |
| # using the between class variance. | |
| ####################################################### |
Hey there, apparently people are still using this Gist from 2013! It's out of date! Consult the Github docs.
These toy examples are for helping with understanding C/C++. There is an excellent C++ samples site which demonstrates many useful things.
| // | |
| // Copyright 2015 Google Inc. All Rights Reserved. | |
| // | |
| // Licensed under the Apache License, Version 2.0 (the "License"); | |
| // you may not use this file except in compliance with the License. | |
| // You may obtain a copy of the License at | |
| // | |
| // http://www.apache.org/licenses/LICENSE-2.0 | |
| // | |
| // Unless required by applicable law or agreed to in writing, software |
In the below keyboard shortcuts, I use the capital letters for reading clarity but this does not imply shift, if shift is needed, I will say shift. So ⌘ + D does not mean hold shift. ⌘ + Shift + D does of course.
| Function | Shortcut |
|---|---|
| New Tab | ⌘ + T |
| Close Tab or Window | ⌘ + W (same as many mac apps) |
| Go to Tab | ⌘ + Number Key (ie: ⌘2 is 2nd tab) |
| Go to Split Pane by Direction | ⌘ + Option + Arrow Key |