This is a fairly common question, and there isn't a One True Answer.
These are the most common techniques:
StringWriter writer = new StringWriter(); | |
e.printStackTrace( | |
new PrintStream( | |
new WriterOutputStream( | |
new PrintWriter(writer) | |
) | |
) | |
); |
# | |
# To check from where a maven dependency comes from | |
# | |
mvn dependency:tree -Dincludes=groupId:artifactId |
java -jar ~/.m2/repository/org/jruby/jruby-complete/1.6.5/jruby-complete-1.6.5.jar -S gem env |
a:not([title]) |
#server.modules += ( "mod_rewrite") | |
# Workaround to have a working reverse-proxy that matches an URL does URL rewriting in Ligghtpd. | |
# | |
# Ligtthpd 1.4.28 cannot perform both matching and URL rewriting at the same time. | |
# Therefore we need to define 2 proxies, one does the matching and bounce the request | |
# to the other one, in charge of rewriting the URL before proxying the request to the target server. | |
# | |
# More about this here: | |
# http://redmine.lighttpd.net/issues/164#note-9 |
ssh-keygen -lf ~/.ssh/id_rsa.pub | |
1024 43:28:56:7f:21:93:02:04:56:af:5f:cb:55:45:e1:67 /users/username/.ssh/id_rsa.pub (DSA) |
System | |
Preferences | |
System Configuration | |
File Associations | |
text /html | |
Move "Iceweasel" to the top of the list | |
Personal | |
Default Applications | |
Web Browser | |
Tick "In an application based on the content of the URL" |
Cherry pick the commits from a through z (assuming SHA1 a is older than z) | |
git rev-list --reverse --topo-order a^..z | xargs -n 1 git cherry-pick | |
The below code does not work as it will squash all the commits (a..z) in a single one. | |
git cherry-pick a..z |