nix, shell, perl, php, mysql and mac os x tips and tricks

Wednesday, September 22, 2010

Use 'find' to recursively chmod files

another 'find' quickie...
find /home/user/files/ -name 'myfile.sh' -exec chmod 755 {} \;

Thursday, September 16, 2010

Capitalize the first letter of a sentence with MYSQL

UPDATE `categories` SET category_name = CONCAT(UCASE(SUBSTRING(`category_name`, 1,1)),LOWER(SUBSTRING(`category_name`, 2)))