$ sudo add-apt-repository ppa:fkrull/deadsnakes
$ sudo apt-get update
$ sudo apt-get install python2.7 python2.7-dev
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 mod(dividend, divisor) { | |
var sDividend = dividend + ''; | |
var split = sDivisor.length + 1; | |
// if dividend < 9007199254740992 (2^53) | |
if (sDividend.length < 16) { | |
return dividend % divisor; | |
} | |
// 'abcdefghijklmnopqrstuvwxyz' => ["qrstuvwxyz", "ghijklmnop", "abcdef"] |
html
<div id="test" data-value="1"></div>
jquery
$('#test').attr('data-value') !== $('#test').data('value');
假如模板上要使用 session
before
app.dynamicHelpers({
session: function (req, res) {
return req.session;
}
});
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
curl https://raw.github.com/creationix/nvm/master/nvm.sh -o ~/nvm/nvm.sh && . ~/nvm/nvm.sh | |
echo ". ~/nvm/nvm.sh" > ~/.bashrc | |
nvm install v0.8.10 |
svn 设置忽略
$ svn propset svn:ignore 'a' .
svn 删除忽略
$ svn propdel svn:ignore 'a' .
找到你要回到的 hash
$ git reset --hard hash
$ git push -f origin master
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
1) .gitmodules | |
2) .git/config | |
3) git rm --cache path/to/module |
OlderNewer