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
#include <stdlib.h> | |
#include <string.h> | |
#include <regex.h> | |
#include <stdio.h> | |
int main() { | |
regex_t *preg = calloc(1, sizeof(regex_t)); | |
int numoffsets = 5; | |
regmatch_t pmatch[numoffsets]; | |
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
Gist should be way faster now. |
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
rails_root = "/data/github/current" | |
20.times do |num| | |
God.watch do |w| | |
w.name = "dj-#{num}" | |
w.group = 'dj' | |
w.interval = 30.seconds | |
w.start = "rake -f #{rails_root}/Rakefile production jobs:work" | |
w.uid = 'git' |
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
speed test. |
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
# +path+ is the full path of the new repo (traditionally ends with /.git)# +path+ is the full path of the new repo (traditionally ends with /.git)# +path+ is the full path of the new repo (traditionally ends with /.git)# +path+ is the full path of the new repo (traditionally ends with /.git) |
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
/* | |
=skin= | |
@name Default | |
@author Yatrik Solanki | |
@homepage http://www.yatriksolanki.com | |
@email yatriksolanki@gmail.com | |
@license MPL/LGPL/GPL | |
=/skin= | |
*/ | |
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
/* | |
=skin= | |
@name Default | |
@author Yatrik Solanki | |
@homepage http://www.yatriksolanki.com | |
@email yatriksolanki@gmail.com | |
@license MPL/LGPL/GPL | |
=/skin= | |
*/ | |
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
>> Dir.entries('_layouts') | |
=> [".", "..", ".svn"] | |
>> Dir.entries('_layouts').reject { |x| File.directory?(x) } | |
=> [".svn"] | |
>> Dir.chdir('_layouts') | |
=> 0 | |
>> Dir.entries('.') | |
=> [".", "..", ".svn"] | |
>> Dir.entries('.').reject { |x| File.directory?(x) } | |
=> [] |
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
bar |
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
var Expr = Sizzle.selectors = { | |
order: [ "ID", "NAME", "TAG" ], | |
match: { | |
ID: /#((?:[\w\u00c0-\uFFFF_-]|\\.)+)/, | |
CLASS: /\.((?:[\w\u00c0-\uFFFF_-]|\\.)+)/, | |
NAME: /\[name=['"]*((?:[\w\u00c0-\uFFFF_-]|\\.)+)['"]*\]/, | |
ATTR: /\[\s*((?:[\w\u00c0-\uFFFF_-]|\\.)+)\s*(?:(\S?=)\s*(['"]*)(.*?)\3|)\s*\]/, | |
TAG: /^((?:[\w\u00c0-\uFFFF\*_-]|\\.)+)/, | |
CHILD: /:(only|nth|last|first)-child(?:\((even|odd|[\dn+-]*)\))?/, | |
POS: /:(nth|eq|gt|lt|first|last|even|odd)(?:\((\d*)\))?(?=[^-]|$)/, |