Skip to content

Instantly share code, notes, and snippets.

View hugobarauna's full-sized avatar

Hugo Baraúna hugobarauna

View GitHub Profile
# by bryan helmkamp with slight modification by chris wanstrath
# from http://www.brynary.com/2008/8/3/our-git-deployment-workflow
module GitCommands
extend self
def diff_staging
`git fetch`
puts `git diff origin/production origin/staging`
end
# http://henrik.nyh.se/2008/12/git-dirty-prompt
# http://www.simplisticcomplexity.com/2008/03/13/show-your-git-branch-name-in-your-prompt/
# username@Machine ~/dev/dir[master]$ # clean working directory
# username@Machine ~/dev/dir[master*]$ # dirty working directory
function parse_git_deleted {
[[ $(git status 2> /dev/null | grep deleted:) != "" ]] && echo "-"
}
function parse_git_added {
[[ $(git status 2> /dev/null | grep "Untracked files:") != "" ]] && echo '+'
# Used to graph results from autobench
#
# Usage: ruby autobench_grapher.rb result_from_autobench.tsv
#
# This will generate three svg & png graphs
require "rubygems"
require "scruffy"
require 'csv'
require 'yaml'
Rails CMS alternatives
======================
Active projects:
---------------
adva-cms
repo: http://github.com/svenfuchs/adva_cms/
site: http://adva-cms.org/
Last update: 11/24/09
"the cutting edge Rails CMS platform"
#!/bin/sh
# Install ImageMagick on Snow Leopard: by kain, improved by mislav and samsoffes
# http://www.icoretech.org/2009/08/install-imagemagick-in-leopard-snow-leopard/
# Work with 64bit kernel mode
set -e
PREFIX=/usr/local
# Passenger users: amend your Apache global configuration with the following directive
# SetEnv PATH /usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin
@hugobarauna
hugobarauna / dabblet.css
Created August 23, 2013 13:59 — forked from lucasmazza/dabblet.css
seta com animacao
/**
* seta com animacao
*/
span {
animation: bounce 0.7s infinite ease;
position: relative;
font-size: 3em;
}
# features/step_definitions/search_steps.rb
When /^I search for "([^"]*)"$/ do |search_term|
search_catalogue_with search_term, :using_direct_model_access
end
# features/support/search_support.rb
module SearchSupport
class SearchAutomator
@hugobarauna
hugobarauna / euro-exchange.livemd
Created August 10, 2023 13:45 — forked from rodrigues/euro-exchange.livemd
💶 Euro Exchange Rates History 📈

💶 Euro Exchange Rates History

Run in Livebook

Mix.install([
  {:briefly, "~> 0.4.1"},
  {:req, "~> 0.3.10"},