bash
Magic space on the current command line
2010/06/25
# For how to set up magic space for Bash see: # – http://www.ukuug.org/events/linux2003/papers/bash_tips/#slide15 # – http://codesnippets.joyent.com/posts/show/1690 man bash 2>/dev/null | less -p …
bash one liner to change/remove test pattern from config file or text file.
2010/06/25
Problem: I had a directory with a lot of config files in the ini file format, i.e. name and value separated by equals. Some/all of these contained some directory names and other values which had to be …
find duplicate entry in a list in bash with sed
2010/06/25
Here I will take an example of rss2email list, but I guess I will be able to pass on the concept. Here is example of the output of the r2e list command: […] 1: …
remove/replace text/path in config file.
2010/06/25
Lot of times I end up changing a particular text in config file to some other text. And when I have to do it for multiple files, all files having the text in multiple places, I end up opening the …
Script to add all the partitions to the fstab.
2010/06/24
I wrote a simple script today to get all the partitions on all the disks and then create <a class="zem_slink freebase/en/fstab" title="Fstab" rel="wikipedia" …
Upload a video to youtube
2010/06/23
[…] <td> <div class="bash codecolorer"> google youtube post <span class="re5">--title</span> <span class="st0">"My …
cdargs – bash cd command with bookmarks and browser.
2010/06/22
cdargs is a <a class="zem_slink freebase/en/bash" title="Bash" rel="homepage" href="http://tiswww.case.edu/php/chet/bash/bashtop.html">bash shell cd with …
concatenate compressed and uncompressed logs
2010/06/21
$ find /var/log/apache2 -name 'access.loggz' -exec <a class="zem_slink freebase/en/gzip" title="Gzip" rel="homepage" href="http://www.gzip.org/">zcat {} ; …
Change pidgin status from the command line
2010/06/16
$ purple-remote "setstatus?status=away&message=AFK" Thanks for the comment oshazard, i wasn’t aware of purple-remote existence. […] <a …
Scripts to create logins from bash command – for creating multiple accounts
2010/06/09
Heres the script: […] cat «EOF > login.sh for i in `cat logins` ; do login=`echo ”$i”|awk -F”:” '{print $2}’`; …
bash completion not working on Fedora
2010/06/06
I had bash completion installed and after that I had made huge changes to my bashrc and also installed bashstyle. After this the bash-completion stopped working. I had to spend a lot of time to figure …
colors in bash – script to display all the possible colors.
2010/06/06
If you wanted to have colors in the bash output (including the colors in PS1-4), don’t you keep wondering how the color code would look on the terminal. So, I wrote this small script to show …