Skip to content

Instantly share code, notes, and snippets.

@showaltb
showaltb / gist:2394751
Created April 15, 2012 20:47
Install ElasticSearch 0.19.2 on CentOS 6.0
# (thanks to https://gist.github.com/1556657)
# As root:
yum install java-1.6.0-openjdk.i686
wget https://github.com/downloads/elasticsearch/elasticsearch/elasticsearch-0.19.2.tar.gz
tar xf elasticsearch-0.19.2.tar.gz
rm elasticsearch-0.19.2.tar.gz
mv elasticsearch-0.19.2 /usr/local/share/elasticshare
@showaltb
showaltb / remove-accidentally-added-file.md
Created August 1, 2015 14:25
Remove a file accidentally added with git commit

If you've created a git commit and accidentally included one or more files you didn't intend to, you can remove those files from the commit and place them back in the "Changed but not updated" or "Untracked files" state. Note: do this only if you have not pushed the commit, since this will rewrite history.

git reset HEAD^ file(s)...

git commit --amend -C HEAD