Get Homebrew installed on your mac if you don't already have it
Install highlight. "brew install highlight". (This brings down Lua and Boost as well)
| =Navigating= | |
| visit('/projects') | |
| visit(post_comments_path(post)) | |
| =Clicking links and buttons= | |
| click_link('id-of-link') | |
| click_link('Link Text') | |
| click_button('Save') | |
| click('Link Text') # Click either a link or a button | |
| click('Button Value') |
Get Homebrew installed on your mac if you don't already have it
Install highlight. "brew install highlight". (This brings down Lua and Boost as well)
| #!/usr/bin/env python | |
| import argparse | |
| import copy | |
| import math | |
| import pickle | |
| import random | |
| from itertools import combinations |
| # Install apt-get packages: | |
| sudo apt-get install build-essential openssl libreadline6 libreadline6-dev curl git-core zlib1g zlib1g-dev libssl-dev libyaml-dev libsqlite3-dev sqlite3 libxml2-dev libxslt-dev autoconf libc6-dev ncurses-dev automake libtool bison subversion pkg-config | |
| # Install chruby: | |
| cd | |
| wget https://github.com/downloads/postmodern/chruby/chruby-0.2.3.tar.gz | |
| tar -xzvf chruby-0.2.3.tar.gz | |
| cd chruby-0.2.3 | |
| sudo make install |
| desc 'rolls back migrations in current branch not present in other' | |
| task :rollback_branch_migrations, [:other_branch] do |t, args| | |
| load "#{Dir.pwd}/Rakefile" | |
| branch_migrations = BranchMigrations.new(args.other_branch) | |
| puts ['Rollback the following migrations', branch_migrations, 'y,n? '] | |
| next if %w[no n NO N].include?(STDIN.gets.chomp) | |
| Rake::Task['environment'].invoke |
| let g:rails_projections = { | |
| \ "config/projections.json": { | |
| \ "command": "projections" | |
| \ }, | |
| \ "spec/features/*_spec.rb": { | |
| \ "command": "feature", | |
| \ "template": "require 'spec_helper'\n\nfeature '%h' do\n\nend", | |
| \ }} | |
| let g:rails_gem_projections = { |
This guide explains the way to setup a production server using Capistrano.
# Gemfile
# Use Capistrano for deployment| #!/bin/bash | |
| sudo kextunload -b com.apple.iokit.BroadcomBluetoothHostControllerUSBTransport | |
| sudo kextload -b com.apple.iokit.BroadcomBluetoothHostControllerUSBTransport |
| # Be sure to save your config files. Optional but I do: | |
| sudo cp /etc/postgresql/9.3/main/postgresql.conf ~ | |
| sudo cp /etc/postgresql/9.3/main/pg_hba.conf ~ | |
| # Package repo (for apt-get) | |
| wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add - | |
| sudo sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt/ precise-pgdg main" >> /etc/apt/sources.list.d/postgresql.list' | |
| # Also probably optional but I like to update sources and upgrade | |
| sudo apt-get update |