Skip to content

Instantly share code, notes, and snippets.

@noxqsgit
noxqsgit / cfg-ex.rb
Last active December 18, 2015 11:09
actionmailer + smtp + CFG
CFG = {
test: {},
prod: {},
dev: {
...
# smtp: { ... }
}
}
@noxqsgit
noxqsgit / rsync.sh
Created April 23, 2013 14:29
rsync local & remote commands
rsync -a server:backups/ backups/foo/
rsync --server --sender -logDtpre.iLsf . backups/
@noxqsgit
noxqsgit / log.coffee
Created April 19, 2013 10:36
console.log
L = -> console.log.apply console, arguments
@noxqsgit
noxqsgit / socat.sh
Created April 18, 2013 15:30
socat -- still testing
socat -d -d -d TCP4-LISTEN:9999,fork,bind=localhost TCP4:192.168.1.222:27017
@noxqsgit
noxqsgit / Gemfile
Last active December 15, 2015 19:09
sqlite -> postgres
source 'https://rubygems.org'
gem 'taps'
gem 'rack', '1.5.0' # see https://github.com/rack/rack/issues/528
gem 'sinatra'
gem 'pg'
gem 'sqlite3'
@noxqsgit
noxqsgit / packages
Created March 21, 2013 13:09
libav/ffmpeg packages
libav-tools
libavcodec-extra-53
libavdevice-extra-53
libavfilter-extra-2
libavformat-extra-53
libpostproc-extra-52
@noxqsgit
noxqsgit / sync-home
Last active December 13, 2015 21:38
sync
#!/bin/bash
host="$HOSTNAME"
exclude_list=(
/.bundle /.cabal /.gem /.node /.npm /.vagrant.d /Downloads /VMs
/opt/{pkg,src} /tmp/work/dump
)
for x in "$HOME"/tmp/build/chromium*; do
@noxqsgit
noxqsgit / mongo.bash
Last active December 13, 2015 19:09
mongo dump/restore
ssh -Nv -L 8888:localhost:27017 user1@server1
ssh -Nv -L 9999:localhost:27017 user2@server2
mongodump -h localhost:8888 -d db1 -u user1 -p ''
mongorestore -h localhost:9999 -d db2 -u user2 -p '' dump/db1/
@noxqsgit
noxqsgit / packages
Created February 15, 2013 11:22
iridium
build-essential
byobu
curl
dia
git
gitg
grc
gstreamer0.10-ffmpeg
gstreamer0.10-fluendo-mp3
haskell-platform
@noxqsgit
noxqsgit / git.md
Last active December 11, 2015 13:08
git basics

Learn to use git

--> http://try.github.com

Use git for your project

$ cd /path/to/your/project
$ git init .

Add a bitbucket remote