(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:
| /** | |
| * Returns the state for a postcode. | |
| * eg. NSW | |
| * | |
| * @author http://waww.com.au/ramblings/determine-state-from-postcode-in-australia | |
| * @link http://en.wikipedia.org/wiki/Postcodes_in_Australia#States_and_territories | |
| */ | |
| function findState($postcode) { | |
| $ranges = array( | |
| 'NSW' => array( |
| #! /usr/bin/python | |
| from sys import argv | |
| from os.path import exists | |
| from os import makedirs | |
| from os import symlink | |
| from os import system | |
| import getopt | |
| # |
| #!/bin/sh | |
| ### | |
| # SOME COMMANDS WILL NOT WORK ON macOS (Sierra or newer) | |
| # For Sierra or newer, see https://github.com/mathiasbynens/dotfiles/blob/master/.macos | |
| ### | |
| # Alot of these configs have been taken from the various places | |
| # on the web, most from here | |
| # https://github.com/mathiasbynens/dotfiles/blob/5b3c8418ed42d93af2e647dc9d122f25cc034871/.osx |
| on run argv | |
| (* | |
| Toggle an application from full screen to non full screen (or the reverse). | |
| Parameters: | |
| 1: application name(ie, Chrome) | |
| 2: boolean (true/false). | |
| When true ensure that the application is in full screen mode (if not, make it so) | |
| When false ensure that the application is NOT in full screen mode (if not, make it so) | |
| *) | |
| set theapp to item 1 of argv |
| /** | |
| * Open all external links in a new window | |
| */ | |
| jQuery(document).ready(function($) { | |
| $('a') | |
| .filter('[href^="http"], [href^="//"]') | |
| .not('[href*="' + window.location.host + '"]') | |
| .attr('rel', 'noopener noreferrer') | |
| .attr('target', '_blank'); | |
| }); |
| <?php | |
| class BlogController extends Controller | |
| { | |
| /** | |
| * Posts | |
| * | |
| * @return void | |
| */ | |
| public function showPosts() |
| if application "Spotify" is running and application "iTunes" is not running then | |
| tell application "Spotify" | |
| if player state is stopped then | |
| set display to "No Track Playing" | |
| else | |
| set track_artist to artist of current track | |
| set track_name to name of current track | |
| set track_duration to duration of current track | |
| set seconds_played to player position | |
| set state to "" |