Archive for the 'Learning Linux and Perl' Category

recursive diff

Thursday, July 29th, 2010

How to see differencies in different folders recursively.

diff -u -r -B -N -s FOLDER1 FOLDER2

[http://linux.devquickref.com/linux-recursive-diff.html]

Perl arrays within arrays

Tuesday, March 9th, 2010

http://www.suite101.com/article.cfm/perl/94552

http://www.misc-perl-info.com/perl-array-length.html
EXAMPLE

# Parts and Programme Codes

@PSUB01 = (’PSUB01′,[”Part A”,”Part B”,”Part I”]);
@PSUB02 = (’PSUB01′,[”Part A”,”Part B”]);
@PSUB03 = (’PSUB03′,[”Part A”,”Part B”]);
@PSUB12 = (’PSUB12′,[”Part A”,”Part B”,”Part I”]);
@PSUB13 = (’PSUB13′,[”Part B”,”Part I”]);

@programmecodes = (\@PSUB01,\@PSUB02,\@PSUB03,\@PSUB12,\@PSUB13);

Useful information on getting files (local/urls/etc)

Wednesday, February 24th, 2010

http://www.php-mysql-tutorial.com/wikis/php-tutorial/reading-a-remote-file-using-php.aspx

EAccelerator - max your PHP

Friday, February 19th, 2010

http://www.geektips.net/105/how-to-install-eaccelerator.html

Setting up Yum on FC2

Saturday, February 6th, 2010

http://forums.spry.com/centos-fedora-redhat/201-setting-up-yum-fc2.html

Upgrade to PHP 5 on Plesk 7.5.4

Saturday, February 6th, 2010

http://forums.serverbeach.com/showthread.php?t=6125

Upgrading plesk mysql database

Wednesday, February 3rd, 2010

Great article thanks Jeff:

http://jeffbaier.com/articles/how-to-upgrade-mysql-on-a-server-with-plesk/

PHP regexp to match a URL

Thursday, June 18th, 2009

http://snipplr.com/view/2371/regex-regular-expression-to-match-a-url/

$url = preg_replace(’@(https?://([-\w\.]+)+(:\d+)?(/([\w/_\.]*(\?\S+)?)?)?)@’, ‘$1‘, $url);

Search for installed packages on Linux

Friday, February 6th, 2009

rpm -qa | grep firefox

(searching for firefox for example)

Find files larger than 50mb on Linux through the command line

Thursday, February 5th, 2009

find / -type f -size +50000k -exec ls -lh {} \; | awk ‘{ print $9 “: ” $5 }’