Ask HN: What does your favorite custom shell script do?
While we may talk often about other pieces of the software development lifecycle, shell scripts don't usually get to take center stage. Let's share some creative little scripts we've come up with over the years!
5 comments
[ 3.2 ms ] story [ 19.7 ms ] threadwhen you type bm, it lists the bookmarks. Select a directory, and it cd's to it. Select a file, and it opens it in vi. Bookmarks can be grouped and sub-grouped and shared with many users on the same linux/unix box.
If enough people are interested, I will publish it somewhere for others to use/adapt/improve.
All of them are so trivial but I love them :-D Maybe not so creative tho ;c
Designed for overnight backup, hook up a backup drive in the afternoon one day, and put in safe the next morning.
Script mounts and verifies existence of a backup external hdd; creates a backup tar on the drive; deletes all but the last five recent backup archives; then unmounts drive for removal next morning.