Install by running the following command in your terminal:
exec 3<&1;bash <&3 <(curl https://gist.githubusercontent.com/jondkinney/2040114/raw/vim.sh 2> /dev/null)
| /* Daniel Ott | |
| * entities.css | |
| * 31 January 2011 | |
| * | |
| * Adding arrows to thinks makes them more clickable. Right? | |
| * Use CSS's :after pseudo-selector to insert hexadecimal values | |
| * of html entities into the document. Less markup. More awesome. | |
| */ | |
| .add-an-arrow:after { |
| pdf.width_of(text) | |
| pdf.width_of(text, :size => 10) | |
| # or if you have more fonts in layout | |
| @your_font.compute_width_of(text, :size => 8) |
| require 'rubygems' | |
| require 'httparty' | |
| require 'benchmark' | |
| require 'thread' | |
| class Google | |
| include HTTParty | |
| base_uri 'http://google.com' | |
| def self.benchmark |
| #!/usr/bin/env ruby | |
| #/ Usage: <progname> [options]... | |
| #/ How does this script make my life easier? | |
| # ** Tip: use #/ lines to define the --help usage message. | |
| $stderr.sync = true | |
| require 'optparse' | |
| # default options | |
| flag = false | |
| option = "default value" |
| function slugify(text) | |
| { | |
| return text.toString().toLowerCase() | |
| .replace(/\s+/g, '-') // Replace spaces with - | |
| .replace(/[^\w\-]+/g, '') // Remove all non-word chars | |
| .replace(/\-\-+/g, '-') // Replace multiple - with single - | |
| .replace(/^-+/, '') // Trim - from start of text | |
| .replace(/-+$/, ''); // Trim - from end of text | |
| } |
| # This is a short collection of tools that are useful for managing your | |
| # known_hosts file. In this case, I'm using the '-f' flag to specify the | |
| # global known_hosts file because I'll be adding many deploy users on this | |
| # system. Simply omit the -f flag to operate on ~/.ssh/known_hosts | |
| # Add entry for host | |
| ssh-keyscan -H github.com >> /etc/ssh/ssh_known_hosts | |
| # Scan known hosts | |
| ssh-keygen -f /etc/ssh/ssh_known_hosts -F github.com |
| # webm | |
| ffmpeg -i IN -f webm -vcodec libvpx -acodec libvorbis -ab 128000 -crf 22 -s 640x360 OUT.webm | |
| # mp4 | |
| ffmpeg -i IN -acodec aac -strict experimental -ac 2 -ab 128k -vcodec libx264 -vpre slow -f mp4 -crf 22 -s 640x360 OUT.mp4 | |
| # ogg (if you want to support older Firefox) | |
| ffmpeg2theora IN -o OUT.ogv -x 640 -y 360 --videoquality 5 --audioquality 0 --frontend |
| #Gets current time, then formats current time for SQL. | |
| Time.now.to_s(:db) |
| # Install rvm system-wide | |
| bash -s stable < <(curl -s https://raw.github.com/wayneeseguin/rvm/master/binscripts/rvm-installer ) | |
| # Update the packages | |
| apt-get update | |
| apt-get upgrade | |
| apt-get install build-essential | |
| # get the packages required by ruby | |
| rvm pkg install zlib |