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
for i in `git status -s | sed -e 's/^.* //'`; do php -l $i; done |
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
# Assume your svn repo is located at svn://example.com/myapp/trunk | |
# Assume your git repo will be located at [email protected]:example/myapp.git | |
# First you need to generate a list of all committers in your svn tree. | |
# Credit David Wheeler | |
# http://www.justatheory.com/computers/tricks/list-all-svn-committers.html | |
$ svn log --quiet svn://example.com/myapp/trunk | grep '^r' | awk '{print $3}' | sort -u | |
# Next, create a file in your home directory named svn-committers following this format | |
mojombo = Tom Preston-Werner <[email protected]> |
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
// Here my collection is named articles | |
// I'm changing the blog_name field in every document in that collection to lowercase | |
db.articles.find().forEach(function(doc){if(typeof(doc.blog_name) == 'string') {doc.blog_name = doc.blog_name.toLowerCase(); db.articles.save(doc); }}) |
NewerOlder