Skip to content

Instantly share code, notes, and snippets.

Vincent Paca vincentpaca

Block or report user

Report or block vincentpaca

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View s3_concat.rb
require 'aws-sdk'
rspec_bucket = s3.bucket(ENV['RSPEC_BUCKET'])
cukes_bucket = s3.bucket(ENV['CUKES_BUCKET'])
rspec_objects = rspec_bucket.objects(prefix: ENV['CI_BUILD_NUMBER'])
cukes_objects = cukes_bucket.objects(prefix: ENV['CI_BUILD_NUMBER'])
test_group_threshold = ENV['TEST_GROUPS'].to_i
vincentpaca / s3_upload.rb
Last active Oct 6, 2015
View s3_upload.rb
require 'aws-sdk'
rspec_bucket = obj = s3.bucket(ENV['RSPEC_BUCKET']).object("#{ENV['CI_BUILD_NUMBER']}/#{ENV['TEST_GROUP']}")
cukes_bucket = obj = s3.bucket(ENV['CUKES_BUCKET']).object("#{ENV['CI_BUILD_NUMBER']}/#{ENV['TEST_GROUP']}")
log_files.each do |log_file|
bucket = log_file.include?("rspec") ? rspec_bucket : cukes_bucket
vincentpaca / deis_errors1
Last active Aug 29, 2015
Deis wrong ruby versions
View deis_errors1
> cat Gemfile
ruby '2.1.2'
> deis run 'ruby -v'
ruby 1.9.3p194 (2012-04-20 revision 35410) [x86_64-linux]
> deis run 'rake'
/bin/bash: rake: command not found
vincentpaca /
Last active Aug 29, 2015
Deis and Google Cloud Compute Engine integration

fleetctl v0.7.1 fleet v0.7.1 deis v0.11.0

Setting Up Google Cloud utilities

  1. Install the gcloud utility by running curl | bash
  2. Follow the steps.
    • If using zsh, edit your .zshrc file near the bottom and find the lines that were added by the] gcloud util install. Replace with, do the same with completion.
vincentpaca /
Last active Dec 17, 2015
RVM, Ruby and Rails on Ubuntu


Open terminal then run: sudo apt-get install curl

Install RVM with curl -L | bash -s stable --auto

Reload bash with . ~/.bash_profile

Run: rvm requirements should be successful and give you a bunch of text

vincentpaca /
Last active Dec 15, 2015
RVM, Ruby and Rails on OSX

RVM, Ruby and Rails on OSX

  1. Download and install Xcode from the App Store.

  2. Download and install command line tools on Xcode. On the menu go to Preferences > Downloads > Install Command Line Tools

  3. Install homebrew like so:

     ruby -e "$(curl -fsSL"
vincentpaca / gist:1791197
Created Feb 10, 2012
Autotest & Notifications in Ubuntu
View gist:1791197
gem install autotest
gem install autotest-rails-pure
gem install autotest-notification
apt-get install libnotify-bin
vincentpaca / gist:1780816
Created Feb 9, 2012
Textmate + GEdit = GMate on Ubuntu, Ruby on Rails Text Editor
View gist:1780816
sudo add-apt-repository ppa:ubuntu-on-rails/ppa
sudo apt-get update
sudo apt-get install gedit-gmate
sudo apt-get install gedit-plugins
View gist:1696052
1.9.3p0 :002 > BITLY_CLIENT
=> #<Bitly::V3::Client:0xb653398 @default_query_opts={:login=>"yourusername", :apiKey=>"yourkey"}>
1.9.3p0 :001 > BITLY_CLIENT.shorten("")
=> #<Bitly::V3::Url:0xb5658c8 @client=#<Bitly::V3::Client:0xb653398 @default_query_opts={:login=>"yourusername", :apiKey=>"yourkey"}>, @short_url="", @long_url="", @user_hash="xFMlrA", @global_hash="LmvF", @new_hash=false, @user_clicks=nil, @global_clicks=nil, @title=nil, @created_by=nil, @aggregate_link=nil, @clicks_by_minute=nil>
vincentpaca / bitly.rb
Created Jan 28, 2012
Bitly initializer
View bitly.rb
require Rails.root.join('config','initializers','load_config')
BITLY_CLIENT =['bitly_username'], APP_CONFIG['bitly_key'])
You can’t perform that action at this time.