chronx code and stuff

25Feb/100

stupid nano

Posted by oxchronxo

This will allow you to change the default editor of you system. Works for most if not all debian derivatives. SVN commits were really annoying until I switched over to VI.

$ sudo update-alternatives --config editor
Tagged as: , , No Comments
25Feb/100

locating broken symbolic links

Posted by oxchronxo

Want to find broken/dead/dangling symbolic links on your system. There are a lot ways to do this but one of the simplest is to use a package called "symlinks".

$ sudo apt-get install symlinks
$ symlinks -r $(pwd)

once installed you will get output like the following:

messy:    FAKE_PATH/Konfabulator -> Konfabulator-Partner-9.10-week3-5.2.6-1-inflated/
dangling: FAKE_PATH/Konfabulator-5.3-1-191083-1250636017/Konfabulator -> /mtd_down/nfs/devices/partner/Konfabulator
messy:    FAKE_PATH/Konfabulator-5.3-1-191083-1250636017/Konfabulator -> ./Konfabulator.launcher
dangling: FAKE_PATH/Konfabulator-5.3-1-191083-1250636017/Konfabulator -> /mtd_down/nfs/devices/partner/Konfabulator
dangling: FAKE_PATH/Konfabulator-5.4.1-192904-1253669212/Konfabulator -> /mtd_down/nfs/devices/partner/Konfabulator
dangling: FAKE_PATH/Konfabulator-9.10-week3-5.2.6-1/Konfabulator -> /mtd_down/nfs/devices/partner/Konfabulator
dangling: FAKE_PATH/Konfabulator-9.10-week3-5.2.6-1/Konfabulator -> /mtd_down/nfs/devices/partner/Konfabulator
messy:    FAKE_PATH/Konfabulator-9.2-week4-9/Konfabulator -> ./Konfabulator.launcher
messy:    FAKE_PATH/Konfabulator-9.8-week2-5.2.5-6/Konfabulator -> ./Konfabulator.launcher
messy:    FAKE_PATH/Konfabulator-5.3-1-191647-1251428074/Konfabulator -> ./Konfabulator.launcher
messy:    FAKE_PATH/Konfabulator-5.5-1-4994-1255339266/Konfabulator -> ./Konfabulator.launcher
messy:    FAKE_PATH/Konfabulator-5.5-1-5159-1256950502/Konfabulator -> ./Konfabulator.launcher
25Feb/100

file enumeration by readable timestamp

Posted by oxchronxo

This little bash command let's us order files sequentially based on their actual time while being human readable using. This uses the full year and 24 hour time format.

FORMAT: FILE.date +%Y-%m-%d_%H-%M-%S

OUTPUT: FILE.2010-02-25_11-50-32

Hit List Electronic Edgy Emo Chill