Autre exemple de ma flemmardise compulsive. Voici mon /usr/local/bin,
après de nombreuses pertes. Si vous avez ne serait-ce qu'à moitié l'âme d'un
geek (et que vous utilisez Linux), il y a forcémment un de ces scripts qui
vous sauvera la vie. Sauf indication contraire, tout ce qui est disponible ici
est sous licence GPL.
battery_check
Little script that returns some info about the battery. Can also change the
background color depending on battery level. For best results, I use an
transparent .png wallpaper with fvwm and hsetroot.
fixnames
This is one of my neatest scripts. It does recursive renaming of a directory,
processing directories first and then individual files. Suports alternate
filename and some support for duplicate file deletion.
It was written for a migration from an MacOSX server to a windows server, on a
network where users had very bad habbits with file naming.. so included is a
sed line to make all filenames valid under windows.
Fixnames obviously includes a --pretend option and also outputs nice
stats, a progress indicator and full logs of the work done.
See a screenshot here.
listen2
Small script to listen to predefined radio streams on a console.
md5sum-recursive
Recursive md5sum. Not much to say about it..
naughty_replace
Replaces text in files, and can be easily used to recurse in directories with
a command like find . -type f | xargs naughty_replace BillGates LinusTorvalds
It was written when working on a project
with Adobe Flex. Given arguments such as OldName NewName it will do the
following replacements:
OldName -> NewName (obviously)
oldname -> newname
oldName -> newName
No need to say it saved me huge amounts of time
wlsd
Another really nice app (to my point of view). It is used to generate the
pages you are viewing now. It is a geekish script that is best use with some
basic knowledge of bash scripting (like doing loop on a file containing paths
to exectute a command on each of these paths).
I was faced to the following problem: a lot of directories with content, from
which part of it had to be available on the net, with permanent URIs. I did
not want to separate this content from private content, the web tree had to
reflect my filesystem (part of my home dir actually), wanted to minimize the time
needed to setup shared content. I wanted full control of the shared content,
while having as little redundancy as possible (file permissions, misc info).
It is especially suited for when you have a project dir with files, publish
them, then add some more which you will publish later on. I suggest you read
the comments on the file to get a better idea. Some files
are needed, like icons and stylesheets.