Posts Tagged ‘ script ’

Unpacking a .deb file (including scripts)

January 23, 2012
By

While attempting to install a deb package on a slackware system I wanted to check the install script that the package runs. I tried the deb2tgz utility but unfortunately that only left me the files in the package in a ready to install .tgz file. Here’s how to unpack a .deb to obtain both...

Read more »

DNS::ZoneParse has an undocumented $ORIGIN

November 2, 2011
By

I was working writing a few scripts that should update a DNS zone file on the fly. I decided to use the DNS::ZoneParse perl module for convenience. The example there is straightforward for changing MX records so I thought modifying it to modify an A record should be a piece of cake. Right? Wrong!...

Read more »

Automatically sync photos from digikam to your mobile phone

June 22, 2011
By
digikam_logo

I shoot a lot of pictures. My collection keeps growing (for example ~90 Gb right now) and since last year I discovered the joy of using digikam to tag and organize them. I’m using the beta 2.0.0 version and use mysql to store it’s databases (as opposed to the default sqlite) as it’s easier...

Read more »

Imperator

October 11, 2010
By

Read more »

Easily send mail from a bash script

March 18, 2010
By

Did you ever need to have e-mail's sent from within a bash script? Maybe alert you of errors encountered? Me too. Here's an easy way on how to do it:

Read more »

Rename all files in a folder from upper to lower case.

February 12, 2010
By

Sometimes is needed to have all files in a folder in the same case. Here’s a small script to rename all files in the folder to lower case: View Code BASH1 for i in *; do mv $i `echo $i | tr [:upper:] [:lower:]`; done

Read more »

Export a MySQL database using the command line.

February 2, 2010
By
logo-mysql-110x57

Sometimes it’s easier to just drop to the command line then browse for fancy tools like phpMyAdmin. This is useful, especially for quick jobs. View Code BASH1 mysqldump -u user -ppassword your_database > database_backup.sql Of course you need to replace: user – mysql username password – the password your_database – the database you want...

Read more »

Follow Me

Subscribe via RSS