This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# NOTICE: The stop/restart tasks won't work properly due to a bug in the daemons gem | |
# unless you use the ghazel-daemons gem by putting this in your environment.rb file: | |
# | |
# config.gem "ghazel-daemons", :lib => "daemons" | |
# gem "ghazel-daemons" | |
# require "daemons" | |
# | |
# This will force-load the 'ghazel-daemons' gem and make sure it's used instead of | |
# the 'daemons' gem. It works even with the 'daemons' gem installed, so you won't |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Extend hashes by adding one method that allows you to split a hash into an array of equal-sized hashes. | |
# Filter items to be included in the result by adding a selecting block that returns true | |
# if the key/value is to be kept. | |
# Per the usage example, return values are not ordered unless you're using Ruby 1.9 | |
# usage: | |
# a = {1 => 'a', 2 => 'b', 3 => 'c', 4 => 'd', 5 => 'e'} | |
# a.split_into(3) {|k,v| k.instance_of?(Integer)} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class HaveALineWithMatcher | |
# HaveALineWithMatcher is a simple rspec matcher that tests whether strings exist in a file | |
# | |
# = Usage | |
# | |
# 1. place this file in your spec/support directory. | |
# | |
# 2. use it in your specs: | |
# | |
# "/path/to/file".should have_a_line_with "some string" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Based on apidock.org Ubiquity Search: http://gist.github.com/8132 | |
CmdUtils.CreateCommand( | |
{ | |
name: "code", | |
takes: {"function": noun_arb_text}, | |
icon: "http://github.com/fluidicon.png", | |
homepage: "http://tiago.zusee.com", | |
author: {name: "Tiago Bastos", email: "comechao@gmail.com"}, | |
license: "MPL,GPL", | |
description: "Search on Github Code Search", |
NewerOlder