Skip to content

Instantly share code, notes, and snippets.

Andy Waite andyw8

View GitHub Profile
View gist:217a5d62ac060a7031065fe5d9dca648
apps/24pullrequests/spec/models/event_spec.rb:68: context 'for an admin' do
apps/alaveteli/spec/controllers/request_controller_spec.rb:3019: context 'for any other kind of event' do
apps/alaveteli/spec/controllers/widget_votes_controller_spec.rb:26: context 'for a non-logged-in user without a tracking cookie' do
apps/alaveteli/spec/controllers/widget_votes_controller_spec.rb:47: context 'for a non-logged-in user with a tracking cookie' do
apps/alaveteli/spec/controllers/widgets_controller_spec.rb:74: context 'for a non-logged-in user with a tracking cookie' do
apps/alaveteli/spec/controllers/widgets_controller_spec.rb:100: context 'for a non-logged-in user without a tracking cookie' do
apps/alaveteli/spec/controllers/widgets_controller_spec.rb:116: context 'for a logged in user with tracks' do
apps/alaveteli/spec/controllers/widgets_controller_spec.rb:133: context 'for a logged in user without tracks' do
apps/alaveteli/spec/helpers/link_to_helper_spec.rb:26: context 'for external li
View gist:5e9e81279e4ee8638ca9de5700de9a25
#!/bin/bash
# Install a custom MySQL 5.7 version - https://www.mysql.com
#
# To run this script on Codeship, add the following
# command to your project's setup commands:
# \curl -sSL https://raw.githubusercontent.com/codeship/scripts/master/packages/mysql-5.7.sh | bash -s
#
# Add the following environment variables to your project configuration
# (otherwise the defaults below will be used).
# * MYSQL_VERSION
View gist:1246608
require File.dirname(__FILE__) + '/../foo_page'
describe FooPage do
before(:all) do
html = File.open(File.dirname(__FILE__) + '/../fixtures/foo.html').read
doc = Capybara.string(html)
@page = FooPage(doc)
end
View careerbuilder_class_links.md
View email
paypal2005@andywaite.com
@andyw8
andyw8 / new_gist_file
Created Sep 18, 2013
RSync NAS to HDD
View new_gist_file
rsync -a -h --progress "/Volumes/public/source_dir/" "/Volumes/TOSHIBA EXT/nas/public/dest_dir/"
-a archive mode
-h human readable
--progress shoow progress indicator
View gist:6336004

I actually try to do this with OmniFocus (basically a GTD tool). I’ve got projects for things like Open Source, Career Development, Tech Learning, various side projects, and contexts such as Reading, Writing, Coding. As I discover things that might be useful, I add them as ‘tasks’. It’s not a perfect system, e.g. doesn’t let you see progress over time, but it means I always a have list of potential ‘next steps’ to improve in a particular area. I’ve also experimented with using Trello for tracking tech trends and where I should focus my effort: https://trello.com/b/KvxG26kK/tech-learning

View gist:6215907
air:cucumber-rails(master) andy$ be rake
mkdir -p /Users/andy/Dropbox/code/cucumber-rails/cucumber.github.com/api/cucumber-rails/ruby/yardoc
/Users/andy/.rbenv/versions/2.0.0-p247/bin/ruby -S rspec ./spec/cucumber/rails/database_spec.rb ./spec/generators/cucumber/install/install_generator_spec.rb
................
Finished in 0.21889 seconds
16 examples, 0 failures
/Users/andy/.rbenv/versions/2.0.0-p247/bin/ruby -S bundle exec cucumber
Running failed scenarios
Using the default profile...
View gist:6151794
mkdir -p /Users/andy/Dropbox/code/cucumber-rails/cucumber.github.com/api/cucumber-rails/ruby/yardoc
/Users/andy/.rbenv/versions/1.9.3-p385/bin/ruby -S rspec ./spec/cucumber/rails/database_spec.rb ./spec/generators/cucumber/install/install_generator_spec.rb
................
Finished in 0.47639 seconds
16 examples, 0 failures
/Users/andy/.rbenv/versions/1.9.3-p385/bin/ruby -S bundle exec cucumber
Running failed scenarios
Using the default profile...
Feature: Allow Cucumber to rescue exceptions
View remote_touch.py
import sublime_plugin
import os
class RemoteTouch(sublime_plugin.EventListener):
def on_post_save(self, view):
file_name = view.file_name()
needle = "PATH_FOR_YOUR_APP" # change this
if needle in file_name:
project_root = view.window().folders()[0]
relative_path = file_name.replace(project_root + '/', "")
You can’t perform that action at this time.