Skip to content

Instantly share code, notes, and snippets.

View acdesouza's full-sized avatar

Antonio Carlos da Graça Mota Durão de Souza acdesouza

View GitHub Profile
@acdesouza
acdesouza / brew install
Last active August 29, 2015 14:15
OSX install
brew install openssl bash bash-completion brew-cask git heroku-toolbelt imagemagick node mysql postgresql
@acdesouza
acdesouza / openmailto.sh
Created February 11, 2011 21:34
Instalações que faço no meu Ubuntu 10.10 para a máquina de desenvolvimento
#!/bin/sh
google-chrome -remote "openurl(https://mail.google.com/mail?view=cm&tf=0&to=`
echo $1 | sed 's/mailto://'`,new-tab)"
@acdesouza
acdesouza / gist:1226564
Created September 19, 2011 14:06 — forked from viniciusteles/gist:556029
Sete Atitudes para Hackear a Indústria de Software
Sete Atitudes para Hackear a Indústria de Software
By Klaus Wuestefeld
1) Torne-se excelente.
Seja realmente bom em alguma coisa. Não fique só choramingando ou
querendo progredir às custas dos outros. Não pense q pq vc sentou 4
anos numa faculdade ouvindo um professor falar sobre software q vc
sabe alguma coisa. Jogador de futebol não aprende a jogar bola tendo
@acdesouza
acdesouza / bootstrap
Created March 21, 2012 15:29
Environment setup script for my Ruby 1.9.3 / Rails projects. This script MUST be in script directory. And MUST be executed from project root: source script/bootstrap
#!/bin/bash
clear
echo "------------------------------------------------------------------------------------------------------"
echo "Fresh install development enviroment"
echo "Check if you need export http_proxy, before running ;)"
echo "------------------------------------------------------------------------------------------------------"
#############################################################################################################
# Install rvm
#############################################################################################################
if ! type rvm >/dev/null 2>&1; then
@acdesouza
acdesouza / .slate
Created October 5, 2012 18:31
My Slate config
config defaultToCurrentScreen true
config nudgePercentOf screenSize
config resizePercentOf screenSize
# Resize Bindings
bind m:ctrl;alt corner top-left resize:screenSizeX;screenSizeY
# Push Bindings
bind right:ctrl;alt push right bar-resize:screenSizeX/3
bind left:ctrl;alt push left bar-resize:screenSizeX/3
Verifying that +acdesouza is my blockchain ID. https://onename.com/acdesouza
@acdesouza
acdesouza / angular_header.js
Last active May 28, 2016 14:04
Define Angular.JS controller as a header file
# app/application.js
# require_tree app/controllers
angular.module('myApp').controller('fooCtrl', ctrlImpl);
function ctrlImpl () {
"use strict";
var ctrl = myApp.ctrlHeader;
@acdesouza
acdesouza / _config_deploy.rb
Last active April 29, 2017 07:07
Scripts para criação de um servidor Ruby on Rails. Exemplo de config do Capistrano que usa esses scripts.
require 'bundler/capistrano'
set :application, "<nome_projeto>"
set :scm, :git
set :repository, 'git://<url_do_projeto>'
set :user, '<user_allowed_to_connect_with_ssh_on_servers>'
set :domain, '<URL_do_servidor>'
# Using Vagrant? See also: https://gist.github.com/3490513
@acdesouza
acdesouza / .bash_profile
Last active June 27, 2019 03:54
Meu .bash_profile no MacOSX
export LC_CTYPE="utf-8"
export EDITOR=vim
# Turn terminal colors on
export CLICOLOR=1
################################################################################
# Bash PS1
################################################################################
@acdesouza
acdesouza / bash_utils.sh
Last active December 6, 2022 17:50
Bag of useful bash tools created combining multiple commands
# ----------------------------------------------------------------------------------------------------
# Renames all files in a directory removing the inital 3 digits from its filename
# "001 Potato.sh" => "Potato.sh"
# "002-Carrot.sh" => "Carrot.sh"
# "003.Letuce.sh" => "Letuce.sh"
# "1003. Tomato.sh" => "Tomato.sh"
#
# Source: https://stackoverflow.com/a/28305274
# MV is a DESTRUCTIVE command. Check if the mv command is correct.