Latest Posts


To insert characters on the beginning of a line. Example, insert // from line 1 to 10 :1,10s!^!//! Sample in creating folding in vim. Insert #{{{ text here #}}} provided everything was properly setup on vimrc ~/workspace/puppetworks $ cat site.ppnode…
Read more

sed Galore

Find and replace string recursively find /home/penoycentral/whichfolder -type f -print0| xargs -0 sed -i ‘s/oldstring/newstring/g’ If you want to make sure that you are changing which, use the old grep first find /home/penoycentral/whichfolder -type f -print0| xargs -0 grep -i…
Read more

Mercurial hgwebdir on CentOS 6

Note this setup is unsecured and just for the purpose of having my own lab svn repo. Install mercurial on your server yum install mercurial Setup the mercurial site on apache mkdir /var/www/cgi-hgcp /usr/share/doc/mercurial-1.4/hgwebdir.cgi /var/www/cgi-hg/chmod +x /var/www/cgi-hg/hgwebdir.cgi Create the hgweb.config…
Read more