Skip to content

Instantly share code, notes, and snippets.

View warantesbr's full-sized avatar

Willian Arantes warantesbr

View GitHub Profile
@warantesbr
warantesbr / .git_aliases
Last active January 9, 2020 18:42 — forked from rappleg/.git_aliases
Git Aliases
alias vig='vi $HOME/scripts/bash/.git_aliases'
# GIT aliases
alias st='git status --short'
alias rb='git rebase -p'
alias rbi='git rebase -p --interactive'
alias rbm='git rebase -p master'
alias gcp='git cherry-pick'
alias stash='git stash'
alias pop='git stash pop'
@warantesbr
warantesbr / config.el
Created July 13, 2016 19:18 — forked from pao/config.el
One of my config.el files...
(setq w32-get-true-file-attributes nil)
(add-to-list 'load-path
(concat user-emacs-directory
(convert-standard-filename "personal/modules")))
(prelude-require-packages
'(nyan-mode
ag
clang-format
@warantesbr
warantesbr / resque.rake
Created November 6, 2015 06:00 — forked from ewherrmann/resque.rake
Collection of Resque related custom rake tasks from around the web
require 'resque/tasks'
namespace :resque do
def del(key)
Resque.redis.keys(key).each { |k| Resque.redis.del(k) }
end
desc "Resque setup according to installation guide"
task :setup => :environment
brew update
brew versions FORMULA
cd `brew --prefix`
git checkout HASH Library/Formula/FORMULA.rb # use output of "brew versions"
brew install FORMULA
brew switch FORMULA VERSION
git checkout -- Library/Formula/FORMULA.rb # reset formula
## Example: Using Subversion 1.6.17
#
# Install specific version of Homebrew formula
# usage example:
# $ brew-install ssh-copy-id 6.0p1
function brew-install {
local formula version formula_hash
formula=$1
version=$2
cd `brew --prefix`
git_last_commit_id=`git rev-parse --short HEAD`
'use strict';
module.exports = function(grunt) {
// load all grunt tasks
require('matchdep').filterDev('grunt-*').forEach(grunt.loadNpmTasks);
// configurable paths
var paths = {
#create & deploy lamp droplet
#login via ssh as root
#initial setup (ref: http://library.linode.com/getting-started#sph_logging-in-for-the-first-time)
# update /etc/hosts (to "thalassophobia.surrealroad.com")
nano /etc/hosts
#
#!/bin/sh
# Credits to:
# - http://vstone.eu/reducing-vagrant-box-size/
# - https://github.com/mitchellh/vagrant/issues/343
aptitude -y purge ri
aptitude -y purge installation-report landscape-common wireless-tools wpasupplicant ubuntu-serverguide
aptitude -y purge python-dbus libnl1 python-smartpm python-twisted-core libiw30
aptitude -y purge python-twisted-bin libdbus-glib-1-2 python-pexpect python-pycurl python-serial python-gobject python-pam python-openssl libffi5
# benching https://bitbucket.org/sam_saffron/ruby-pg/commits/66a8e1e9c6984c0207d14f81ae8ef8ac69256d84
#
# automatic casting for pg
$: << '/home/sam/Source/ruby-pg/lib'
require 'pg'
require 'benchmark'
require 'active_record'
ActiveRecord::Base.establish_connection(
@warantesbr
warantesbr / hack.sh
Created March 11, 2014 10:34 — forked from erikh/hack.sh
#!/usr/bin/env sh
##
# This is script with usefull tips taken from:
# https://github.com/mathiasbynens/dotfiles/blob/master/.osx
#
# install it:
# curl -sL https://raw.github.com/gist/2108403/hack.sh | sh
#