This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | ssh <username>@<hostname> 'pg_dump -U <remote_db_user> <remote_db_name>' > <local_filename>.sql | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | scope.$watch('<variable>', function(<value>) { | |
| $timeout(function() { | |
| asyncronousCallback(<value>) | |
| }, 500) | |
| }, true) | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | h1. Sublime Text 2 - Useful Shortcuts (PC) | |
| Loosely ordered with the commands I use most towards the top. Sublime also offer "full documentation":http://www.sublimetext.com/docs/2/. | |
| h2. Editing | |
| | *Ctrl+C* | copy current line (if no selection) | | |
| | *Ctrl+X* | cut current line (if no selection) | | |
| | *Ctrl+⇧+K*| delete line | | |
| | *Ctrl+↩* | insert line after | | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | #!/usr/bin/env bash | |
| # Delete .pyc files | |
| cd ./$(git rev-parse --show-cdup) | |
| # Delete OS X DS_Store files | |
| find . -name ".DS_Store" -delete | |
| TOTAL_PYC_FILES=$( find . -name "*.pyc" | wc -l | tr -d ' ' ) | |
| if [ $TOTAL_PYC_FILES -gt 0 ]; then | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | """ Simple youtube downloader """ | |
| import re | |
| import sys | |
| import requests | |
| import urllib | |
| def youtube_info(youtube_id): | |
| """ Raises ValueError when video is not streamable - e.g. VEVO video """ | |
| info_url = 'http://www.youtube.com/get_video_info?video_id={0}' | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | #!/bin/sh | |
| wget https://bugs.launchpad.net/bugs/971876/+attachment/2991730/+files/rts_bpp.tar.bz2 | |
| tar jxf rts_bpp.tar.bz2 | |
| cd rts_bpp | |
| make | |
| su -c 'make install ; modprobe rts_bpp ; depmod -a' | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | <!-- Standard Favicon --> | |
| <link rel="icon" type="image/x-icon" href="favicon.ico" /> | |
| <!-- For iPhone 4 Retina display: --> | |
| <link rel="apple-touch-icon-precomposed" sizes="114x114" href="http://www.example.com/apple-touch-icon-114x114.png"> | |
| <!-- For iPad: --> | |
| <link rel="apple-touch-icon-precomposed" sizes="72x72" href="http://www.example.com/apple-touch-icon-72x72.png"> | |
| <!-- For iPhone: --> | |
| <link rel="apple-touch-icon-precomposed" href="http://www.example.com/apple-touch-icon-57x57.png"> | |
| <!-- Facebook --> | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | #!/usr/bin/env python | |
| import os | |
| import re | |
| import subprocess | |
| import sys | |
| modified = re.compile('^(?:M|A)(\s+)(?P<name>.*)') | |
| CHECKS = [ | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | class Color(object): | |
| """ | |
| utility to return ansi colored text. | |
| """ | |
| colors = { | |
| 'black': 30, | |
| 'red': 31, | |
| 'green': 32, | |
| 'yellow': 33, |