This file contains hidden or 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
haha |
This file contains hidden or 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
git config --global user.name "houkanshan" | |
git config --global user.email "xxx" | |
git config --global color.ui true | |
git config --global core.editor "vim" | |
git config --global alias.co checkout |
This file contains hidden or 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
//用这个在人人发状态, 可以做到........ 让你的最近一条状态为'什么也没做...' | |
//支持renren新旧版本. | |
//呵呵 | |
(function(document){ | |
var h_iframes = document.getElementsByTagName('iframe'); | |
var proxy; | |
var id; | |
var patten = /status/g; | |
var text = document.getElementsByClassName('status-content')[0].value; |
This file contains hidden or 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 a = [[1492], [6656], [8759], [63166], [9287], [4369], [8811], [7556], [6262], [14399], [64357], [64353], [10546], [6450], [63794], [61408], [60467, 60463, 30321, 30325, 5103, 9471, 8510, 30243, 5103, 9471, 8510, 30321, 30325, 60467, 60463], [63413, 878, 10006, 64901], [57367, 10006, 64901, 14548, 14505], [10006, 64901, 30321, 30325, 6877, 9480, 30243, 6877, 9480, 30321, 30325, 10006, 64901], [57367, 10006, 64901, 30321, 30325, 14624, 61401, 30243, 14624, 61401, 30321, 30325, 57367, 10006, 64901], [62995, 4015, 62638, 64946, 30321, 30325, 3339, 7703, | |
30243, 3339, 7703, 30321, 30325, 62995, 4015, 62638, 64946], [10035, 9470, 8711, 30321, 30325, 3339, 7703, 30243, 3339, 7703, 30321, 30325, 10035, 9470, 8711], [62427, 643, 643], [6952, 14674, 10728], [10851, 10827, 14674, 10728], [30263, 30266, 30246, 30248, 30256, 30256, 30267], [30257, 30266, 30262, 30259, 30321, 30325, 30248, 30256, 30256, 30267, 30243, 30248, 30256, 30256, 30267, 30321, 30325, 30257, 30266, 30262, 30259], [12150, 2272, 11 |
This file contains hidden or 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
/* less.js | |
* detect files change and lessc it | |
* | |
* usage: node less.js [-x] INFILE -d OUTFILE | |
* */ | |
var fs = require('fs'), | |
walk = require('walk'), | |
exec = require('child_process').exec, | |
path = require('path'); |
This file contains hidden or 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
# colors defined with tput | |
function parse_git_branch { | |
ref=$(git symbolic-ref HEAD 2> /dev/null) || return | |
echo "(git:"${ref#refs/heads/}")" | |
} | |
# must put \[ and \] around any non-printing escape sequences | |
# http://mywiki.wooledge.org/BashFAQ/053 | |
export PS1="\[\e[1;34m\][\t]""\[\e[1;32m\]\u""\[\e[0;0m\]@""\[\e[1;32m\]\H""\[\e[0;0m\]:\w\n\[\e""[0;36m\]\$(git_branch)\$""\[\e[0;0m\] " |
This file contains hidden or 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
<!DOCTYPE HTML> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<title></title> | |
<script src="./test.js" type="text/javascript"></script> | |
</head> | |
<body> | |
<span id="test"></span> | |
</body> |
This file contains hidden or 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
# From https://github.com/mojombo/jekyll/issues/463 | |
# but run error on my jekyll. | |
# add a comments to stop jekyll auto omit the 'script' end-tag | |
# usage {% gist gist_id %} | |
module Jekyll | |
class GistTag < Liquid::Tag | |
def initialize(tag_name, text, tokens) |
This file contains hidden or 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
div.box | |
div.inner1 | |
div.inner2 |
This file contains hidden or 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 | |
# for git < 1.7.2 | |
# from http://stackoverflow.com/questions/1994463/how-to-cherry-pick-a-range-of-commits-and-merge-into-another-branch/1994491#1994491 | |
if [ -z $1 ]; then | |
echo "Equivalent to running git-cherry-pick on each of the commits in the range specified."; | |
echo ""; | |
echo "Usage: $0 start^..end"; | |
echo ""; |
OlderNewer