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
[core] | |
pager = less | |
[alias] | |
st = status | |
ci = commit | |
br = branch | |
co = checkout | |
df = diff | |
lg = log -p | |
[user] |
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
#!/bin/bash | |
# $Id: /mirror/codecheck.in/platform/linux/misc/backlog_svn_sync.sh 9698 2008-08-25T13:12:27.251994Z dragon3 $ | |
# | |
# Script to svnsync "Backlog" project repository. | |
# | |
if [ $# -ne 2 ]; then | |
echo "Usage: $0 [space key] [project key]" | |
exit 1; | |
fi |
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 F = function() { | |
this.foo = function() { return "foo" }; | |
} | |
var f = new F(); | |
console.log(f.foo()); // foo | |
F.prototype.foo = function() { return "prototype.foo" }; |
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
function Deferred() { console.log(this); return (this instanceof Deferred) ? this.init() : new Deferred() } | |
Deferred.prototype = { | |
init: function() { console.log("init"); } | |
}; | |
new Deferred(); | |
Deferred(); | |
//Object |
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
str = 'fooBar' | |
if ( (match = str[/^[A-Z]/]) != nil ) | |
p match | |
end |
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
p "HogeCamelCase".split('').each_with_index.map{ |i, index| | |
i.downcase! && index != 0 ? "_" + i : i | |
}.join('') |
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
;; | |
;; custom url-generator for typing-outputz.el | |
;; | |
(defun my-typing-outputz-url-generator () | |
(typing-outputz-percent-encode | |
(replace-regexp-in-string | |
"c\\+\\+" "cpp" | |
(format "http://%s.localhost/" | |
(symbol-name major-mode))))) | |
(setq typing-outputz-url-generator-function 'my-typing-outputz-url-generator) |
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
;;; pit.el --- Manipulate pit data. | |
;; Copyright (C) 2008 Takeru Naito | |
;; Author: Takeru Naito <takeru.naito@gmail.com> | |
;; Original: cho45 http://lowreal.rubyforge.org/pit/ | |
;; This file is free software; you can redistribute it and/or modify | |
;; it under the terms of the GNU General Public License as published | |
;; by the Free Software Foundation; either version 2, or (at your | |
;; option) any later version. |
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
/* | |
* TechTouch #0b10001 | |
* | |
* kill parent | |
*/ | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <unistd.h> | |
#include <sys/types.h> | |
#include <sys/wait.h> |
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
#!/usr/bin/perl | |
use strict; | |
use warnings; | |
use LWP::UserAgent; | |
my $ua = LWP::UserAgent->new; | |
$ua->agent( | |
"Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)"); | |
my $res = $ua->get("http://twitter.jp"); |
OlderNewer