Skip to content

Instantly share code, notes, and snippets.

Avatar

Jacob Chapel chapel

View GitHub Profile
@SlexAxton
SlexAxton / .zshrc
Last active Jan 2, 2021
My gif workflow
View .zshrc
gifify() {
if [[ -n "$1" ]]; then
if [[ $2 == '--good' ]]; then
ffmpeg -i $1 -r 10 -vcodec png out-static-%05d.png
time convert -verbose +dither -layers Optimize -resize 600x600\> out-static*.png GIF:- | gifsicle --colors 128 --delay=5 --loop --optimize=3 --multifile - > $1.gif
rm out-static*.png
else
ffmpeg -i $1 -s 600x400 -pix_fmt rgb24 -r 10 -f gif - | gifsicle --optimize=3 --delay=3 > $1.gif
fi
else
@coreyti
coreyti / something.html.erb
Created Nov 30, 2012
blacklist select javascript errors from being reported to Airbrake/Hoptoad
View something.html.erb
<%#
NOTES:
* Works with current version (0.1.0) notifier.js hosted at:
http://airbrake.io/javascripts/notifier.js (also https://...)
* Does not need to be HTML or ERB. You just need some way to get your
Airbrake API key and other server-side variables into the javascript.
* This example uses jQuery to load the notifier.js script. Feel free to
adjust as desired for framework-independence.
%>
@bhenerey
bhenerey / ideal ops.md
Created May 23, 2012
ideal ops checklist
View ideal ops.md

In a perfect world, where things are done well, not just quickly, I would expect to find the following when joining the company:

Documentation

  • Accurate / up-to-date systems architecture diagram

  • Accurate / up-to-date network diagram

  • Out-of-hours support plan

  • Incident management plan

@thatch45
thatch45 / gist:2563169
Created Apr 30, 2012
Install from source
View gist:2563169
'make && make install':
cmd.run:
- unless: 'cat /usr/bin/redis'
- require:
- cmd: 'git clone <redis source>'
'git clone <redis source>':
cmd.run:
- unless: 'test -e /usr/src/redis'
- cwd: /usr/src
@torgeir
torgeir / install_redis_on_ubuntu.md
Last active Jun 7, 2018 — forked from lucasmazza/script.md
Redis 2.4.8 Install on Ubuntu 10.04
View install_redis_on_ubuntu.md

Installation commands:

$ wget http://redis.googlecode.com/files/redis-2.4.8.tar.gz
$ tar xvfz redis-2.4.8.tar.gz 
$ cd redis-2.4.8/
$ mkdir -p /opt/redis
$ make PREFIX=/opt/redis install
$ cp redis.conf /opt/redis/redis.conf
$ chown -R redis:redis /opt/redis
@mattmccray
mattmccray / backbone_helper.coffee
Created Oct 14, 2010
Use Backbone.js classes as native CoffeeScript classes
View backbone_helper.coffee
# Backbone CoffeeScript Helpers by M@ McCray.
# Source: http://gist.github.com/625893
#
# Use Backbone classes as native CoffeeScript classes:
#
# class TaskController extends Events
#
# class TaskView extends View
# tagName: 'li'
# @SRC: '<div class="icon">!</div><div class="name"><%= name %></div>'
View setting_up_a_new_remote_git_repository.textile

(a gist based on the old toolmantim article on setting up remote repos)

To collaborate in a distributed development process you’ll need to push code to remotely accessible repositories.

This is somewhat of a follow-up to the previous article setting up a new rails app with git.

For the impatient

Set up the new bare repo on the server: