Skip to content

Instantly share code, notes, and snippets.

Avatar

Chris Laco claco

View GitHub Profile
View Dockerfile
FROM debian:wheezy
RUN echo 'debconf debconf/frontend select Noninteractive' | debconf-set-selections
RUN apt-get update && \
apt-get upgrade -y && \
apt-get autoclean
View keybase.md

Keybase proof

I hereby claim:

  • I am claco on github.
  • I am claco (https://keybase.io/claco) on keybase.
  • I have a public key whose fingerprint is D4B5 9C03 E9E2 960F 3118 8168 8286 F09D FEC8 72AD

To claim this, I am signing this object:

View api.rb
require 'uri'
class ::Chef::Recipe
include ::Openstack
end
View gist:6194705
{
"name": "development",
"description": "",
"cookbook_versions": {
"apache2": "= 1.6.7",
"apt": "= 2.0.1",
"aws": "= 0.101.3",
"build-essential": "= 1.4.1",
"ceilometer": "= 0.0.1",
"cinder": "= 0.0.10",
View gist:5912133
# Attributes
default["some"]["thing"] = "foop"
# Recipe
# This prints the value
Chef::Log.warn node["some"]["thing"]
template "farp" do
source "farp.erb"
variables(
View Gemfile.lock
GIT
remote: git://github.com/opscode/test-kitchen.git
revision: bf17d76df4c63bb58f70dd32ce0deb1b09b9df8d
branch: 1.0
specs:
test-kitchen (1.0.0.dev)
celluloid
mixlib-shellout
net-scp
net-ssh
@claco
claco / gist:3660445
Created Sep 6, 2012
Quick test running for test unit/rspec sans all the other plugins hupla.. current test under cursor, current file, current suite; puts errors in QuickFix. Uses m instead of testrb for test unit line support.
View gist:3660445
autocmd BufNewFile,BufRead *_test.rb setlocal makeprg=m errorformat=%A%>\ \ %n)\ Failure:,%C%m\ [%f:%l]:,%Z
autocmd BufNewFile,BufRead *_test.rb setlocal makeprg=m errorformat+=%A%>\ \ %n)\ Error:,%C%.%#:,%C%m\ for\ #<%.%#>,%Z\ \ \ \ %f:%l:in\ \`%.%#\',%-G%.%#
"autocmd BufNewFile,BufRead *_spec.rb setlocal makeprg=rspec errorformat=rspec\ %f:%l\ #\ %m,%-G%.%#
autocmd BufNewFile,BufRead *_spec.rb setlocal makeprg=rspec errorformat=%A%>\ \ %n)%.%#,%C%>\ \ \ \ \ Failure/Error:%.%#,%C\ \ \ \ \ %m:,%C\ \ \ \ \ \ \ ,%C\ \ \ \ \ \ \ %m,%C\ \ \ \ \ #\ %f:%l:in%.%#,%Z,%-G%.%#
function! RunMake(...)
if a:0 == 1
echo "Running " . &makeprg . " " . a:1 . "..."
silent exec "make! " . a:1
@claco
claco / gist:1888612
Created Feb 23, 2012
Pomodoro on Alfred
View gist:1888612
on alfred_script(q)
tell application "Pomodoro"
if q is equal to "reset" then
reset
else if q is equal to "resume" then
resume
else if q is equal to "complete" then
force completion
else if q is equal to "external" then
View database.yml.example mysql2
# MySQL. Versions 4.1 and 5.0 are recommended.
#
# Install the MySQL driver:
# gem install mysql2
#
# And be sure to use new-style password hashing:
# http://dev.mysql.com/doc/refman/5.0/en/old-client.html
development:
adapter: mysql2
encoding: utf8
View gist:1498636
desc 'Install MacVim'
task :macvim do
system 'git clone git://github.com/b4winckler/macvim.git ~/Downloads/macvim'
system 'cd ~/Downloads/macvim && git pull'
system 'cd ~/Downloads/macvim && make clean'
system 'cd ~/Downloads/macvim && ./configure --with-features=huge --enable-perlinterp --enable-pythoninterp --enable-rubyinterp --enable-cscope --with-tlib=ncurses --enable-multibyte'
system 'cd ~/Downloads/macvim && make'
system 'rm -rf /Applications/MacVim.app'
system 'cd ~/Downloads/macvim && cp -R ~/Downloads/macvim/src/MacVim/build/Release/MacVim.app /Applications'
system 'cd ~/Downloads/macvim && cp ~/Downloads/macvim/src/MacVim/mvim /usr/local/bin'
You can’t perform that action at this time.