Skip to content

Instantly share code, notes, and snippets.

@rodrigomaia
rodrigomaia / happynel.md
Last active July 1, 2019 16:26
Teste Ruby on Rails

HappyNel

Dashboard de enquete de satisfação

Requerimentos

  1. Rails 5
  2. Git - Ceder acesso ao repositório. Pode ser no Bitbucket, Github, Gitlab...
  3. Faça o deploy da aplicação em algum serviço externo, como Heroku, Digital Ocean ou outro de sua preferência.
@rodrigomaia
rodrigomaia / new_gist_file
Created May 2, 2013 14:44 — forked from billsinc/gist:1157544
Desinstalar o firebird
#!/bin/sh
echo "Clean Services"
echo "Clean User"
dscl localhost -delete /Local/Default/Users/firebird
echo "Clean Group"
dscl localhost -delete /Local/Default/Groups/firebird
if [ -f "/Library/StartupItems/Firebird" ]; then
echo "Remove SuperServer StartupItem"
rm -fr /Library/StartupItems/Firebird
fi
@rodrigomaia
rodrigomaia / gist:4260245
Created December 11, 2012 16:54
Getting Started with Engines
rails plugin new sudy_ag --full
# copiar as migrations pro hospedeiro
rake sudy_ag_engine:install:migrations
fonte: http://guides.rubyonrails.org/engines.html
@rodrigomaia
rodrigomaia / gist:2781396
Created May 24, 2012 12:53
[RSpec] How to get instance that was invoked a stub method on any_instance
ANYCLASS.any_instance.stub(:METHOD) do |METHOD_PARAM|
INSTANCE_ANYCLASS = ANYCLASS.__recorder.instance_that_received(:METHOD)
end
# See docs:
# AnyInstance => http://rubydoc.info/github/rspec/rspec-mocks/RSpec/Mocks/AnyInstance
# Recorder => http://rubydoc.info/github/rspec/rspec-mocks/RSpec/Mocks/AnyInstance/Recorder
@myobie
myobie / mountain-lion-brew-setup.markdown
Created February 18, 2012 20:14
Get Mountain Lion and Homebrew to Be Happy

Get Mountain Lion and Homebrew to Be Happy

1) Install XCode 4.4 into /Applications

Get it from the App Store.

2) Install Command Line Tools

In XCode's Preferences > Downloads you can install command line tools.