- Some utilities:
sudo apt-get install vim tmux git- Copy/paste from the command line:
sudo apt-get install xclip| require 'builder' | |
| module MacApp | |
| class << self | |
| def new | |
| ask_name | |
| ask_file_extension | |
| ask_language | |
| create_directories |
| source :rubygems | |
| # We are not loading Active Record, nor Active Resources etc. | |
| # We can do this in any app by simply replacing the rails gem | |
| # by the parts we want to use. | |
| gem "actionpack", "~> 3.2" | |
| gem "railties", "~> 3.2" | |
| gem "tzinfo" | |
| # Let's use thin |
| # Update, upgrade and install development tools: | |
| apt-get update | |
| apt-get -y upgrade | |
| apt-get -y install build-essential | |
| apt-get -y install git-core | |
| # Install rbenv | |
| git clone git://github.com/sstephenson/rbenv.git /usr/local/rbenv | |
| # Add rbenv to the path: |
Just install this in your apps like so:
gem 'test-spec-mini', :git => 'git://gist.github.com/1806986.git', :require => 'mini'
This installs a patched ruby 1.9.3-p327 with various performance improvements and a backported COW-friendly GC, all courtesy of funny-falcon.
You will also need a C Compiler. If you're on Linux, you probably already have one or know how to install one. On OS X, you should install XCode, and brew install autoconf using homebrew.
| source :rubygems | |
| gem 'json' | |
| gem 'rake', :require => ['rake/testtask'] | |
| gem 'rake-compiler', :require => ['rake/extensiontask', 'rake/javaextensiontask'] | |
| gem 'activesupport' | |
| group :deploy do | |
| gem 'git' | |
| gem 'yard' |
| var http = require('http'); | |
| // The url we want, plus the path and options we need | |
| var options = { | |
| host: 'localhost', | |
| port: 8124, | |
| path: '/?file=secondary', | |
| method: 'GET' | |
| }; |
| require 'benchmark/ips' | |
| GC.disable | |
| class Foo | |
| def baz; end | |
| define_method(:foo) { } | |
| class_eval 'def bar; end' | |
| end |
| gem install mysql | |
| Building native extensions. This could take a while... | |
| ERROR: Error installing mysql: | |
| ERROR: Failed to build gem native extension. | |
| /Users/tbrock/.rbenv/versions/2.0.0-p247/bin/ruby extconf.rb | |
| checking for mysql_ssl_set()... *** extconf.rb failed *** | |
| Could not create Makefile due to some reason, probably lack of necessary | |
| libraries and/or headers. Check the mkmf.log file for more details. You may | |
| need configuration options. |