This gist shows how to create a GIF screencast using only free OS X tools: QuickTime, ffmpeg, and gifsicle.
To capture the video (filesize: 19MB), using the free "QuickTime Player" application:
| // Disable bold. | |
| term_.prefs_.set('enable-bold', false) | |
| // Use this for Solarized Dark | |
| term_.prefs_.set('background-color', "#002b36"); | |
| term_.prefs_.set('foreground-color', "#839496"); | |
| term_.prefs_.set('color-palette-overrides', [ | |
| '#073642', | |
| '#dc322f', |
| require 'thread' | |
| require 'csv' | |
| require 'net/http' | |
| require 'json' | |
| id = 0 | |
| max_id = 30 | |
| class Atomic | |
| def initialize(val) |
| [[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm" # Load RVM into a shell session *as a function* | |
| # Git | |
| alias gs="git status" | |
| alias ga="git add" | |
| alias go="git checkout" | |
| alias gc="git commit" | |
| alias gl="git log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --date=relative" | |
| alias gp="git push" |
| require 'rubygems' | |
| require 'simpler_tiles' | |
| breaks = [0.05, 0.15, 0.30, 0.45, 0.60] | |
| cbreaks = [0.40, 0.50, 0.60, 0.70, 0.80] | |
| colors = [[236, 231, 242], [166, 189, 219], [116, 169, 207], [54, 144, 192], [5, 112, 176], [3, 78, 123]] | |
| def color(color) | |
| sprintf("#%2x%2x%2x", *color).gsub(" ", "0") | |
| end |
| #!/usr/bin/env ruby | |
| cmds = [] | |
| cmds << "git co gh-pages" | |
| cmds << "git merge master" | |
| cmds << "git push github gh-pages" | |
| cmds << "git co master" | |
| system cmds.join("&&") |
| session: | |
| name: "electris" | |
| windows: | |
| - name: "term" | |
| clear: true | |
| root: "~/src/electris" | |
| filters: | |
| before: | |
| - "workon electris" | |
| splits: |
Open Source code doesn’t always come in big complex packages. At ProPublica we sometimes share small, simple snippets of using GitHub "Gists." These Gists range from single-byte file delimiters to an entire JavaScript framework for making stepper graphics. They rarely have documentation and don’t even always have names, but they can be super-useful. Here are some we’ve shared over the past few years:
| // MIXINS | |
| vendor(prop, args) | |
| -webkit-{prop} args | |
| -moz-{prop} args | |
| -o-{prop} args | |
| {prop} args | |
| animation() | |
| vendor('animation', arguments) |