Skip to content

Instantly share code, notes, and snippets.

View danielb2's full-sized avatar

Daniel Bretoi danielb2

View GitHub Profile
# Copyright (c) 2008, Daniel Bretoi <daniel@bretoi.com>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
# * Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# * Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in the
# documentation and/or other materials provided with the distribution.
#!/usr/bin/env ruby
gem 'bson_ext', '1.0.4'
gem "mongoid", '2.0.0.beta.19'
require 'mongoid'
require 'fabrication'
Mongoid.configure do |config|
name = "test"
host = "localhost"
config.master = Mongo::Connection.new.db(name)
require 'spec_helper'
describe InvitesController do
def mock_invite(stubs={})
@mock_invite ||= mock_model(Invite, stubs).as_null_object
end
describe "GET index" do
it "assigns all invites as @invites" do
set-option -g prefix C-a
set default-path $PWD
unbind-key C-b
bind-key C-a last-window
bind-key a send-prefix # allows to send ctrl-a directly to window
bind-key space next-window
bind-key C-space next-window
bind-key l select-pane -L
bind-key h select-pane -R
ralias "irb irb -r 'irb/completion'"
ralias "grep grep --color=always"
ralias "urls vim #{ENV['HOME']}/misc/urls"
ralias "bos vim #{ENV['HOME']}/misc/bos"
ralias "contacts vim #{ENV['HOME']}/misc/contacts"
ralias 'findd find . | grep -i'
ralias 'phpi rlwrap -a -- php -a'
ralias 'ls ls -Gh'
#ralias 'pss ps wuax | grep -i'
#ralias 'ls gls -h --color'
[~/tmp/foo]$ cat .gitignore
*.gem
*.rbc
.bundle
.config
.yardoc
Gemfile.lock
InstalledFiles
_yardoc
coverage
import weechat
SCRIPT_NAME = "test"
SCRIPT_AUTHOR = "test"
SCRIPT_VERSION = "0.0"
SCRIPT_LICENSE = "GPL3"
SCRIPT_DESC = "test"
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>com.ilovezfs.mac.zfs.zpool-import</string>
<key>ProgramArguments</key>
<array>
<string>/usr/local/sbin/zpool</string>
<string>import</string>
#!/usr/bin/env ruby
# encoding: utf-8
issue_no = ARGV.shift
system "git co -b issue.#{issue_no}-" + ARGV.join('.')
===>>> The following actions will be taken if you choose to proceed:
Install net/netatalk3
Install databases/db5
Install devel/dbus-glib
Install devel/dbus
Install sysutils/gnome_subr
Install textproc/expat2
Install textproc/xmlto
Install misc/getopt