sam87
another day in voodoo land.....
Monday, December 15, 2014
How long has it been?
When I look at my old posts and I look at myself now, I really have changed. Damn. Younger me, I like him a lot. He knew how to have fun.
Thursday, August 25, 2011
my little perl script to uncomment the mirrorlist
so am a perl newbie and i want to start writing little utilities that make it easy for me to do stuff. i have just written a little script that lets me uncomment the Servers in mirrorlist contained in /etc/pacman.d/mirrorlist and its working pretty good. its not the best but hey, it works for me:
#!/usr/bin/perl
#
use strict;
use warnings;
open MIRRORS, "/home/me/mirrorlist";
my $i = 0;
while () {
if (/(Server.*)/) {
print "$1\n";
}
}
close MIRRORS;
i then ./mirrors.pl > mymirrorlist
and rankmirrors -n 6 mymirrorlist > mirrorlist
tada!
[EDIT]
this can even run better like this, i just learnt to do subs, so
#!/usr/bin/perl
#
use strict;
use warnings;
open MIRRORS, "/home/tehpwnz/perl/mirrorlist";
open MYLIST, ">/home/tehpwnz/perl/list";
my $i = 0;
while () {
#if(/[#]Server.*(http|ftp)/) {
# print "found";
#}
if (/(Server.*)/) {
s/#//;
print MYLIST;
}
}
close MIRRORS;
close MYLIST;
#!/usr/bin/perl
#
use strict;
use warnings;
open MIRRORS, "/home/me/mirrorlist";
my $i = 0;
while (
if (/(Server.*)/) {
print "$1\n";
}
}
close MIRRORS;
i then ./mirrors.pl > mymirrorlist
and rankmirrors -n 6 mymirrorlist > mirrorlist
tada!
[EDIT]
this can even run better like this, i just learnt to do subs, so
#!/usr/bin/perl
#
use strict;
use warnings;
open MIRRORS, "/home/tehpwnz/perl/mirrorlist";
open MYLIST, ">/home/tehpwnz/perl/list";
my $i = 0;
while (
#if(/[#]Server.*(http|ftp)/) {
# print "found";
#}
if (/(Server.*)/) {
s/#//;
print MYLIST;
}
}
close MIRRORS;
close MYLIST;
Wednesday, January 19, 2011
nothing like you and me...on the beach
okay so there was a time when i thot this would never happen to me, but it did.I fell for someone, her name, am not saying, but she's the most beautiful thing ever...i took her to the beach once and i had the night of my life...from different backgrounds with different interests...but still...we clicked....there's nothing like you and me..on the beach...out of reach and there never will be anything like it...EVER!!!
Friday, May 21, 2010
ZOMFG!!! FreeBSD!!!
okay so i've been using Linux for 2 years now and am quite geeky, but it seems not geeky enough!!! FreeBSD took me the whole day to install, and then am done with installing, after a WHOLE day, and i realise what?NO NETWORKING! i can't network at all, nothing! meaning no ports collection or anything...FreeBSD, not for the faint hearted....eish..i won't be trying that again for a long time to come! I guess i'll stick to arch linux, home is where the heart is :)
Wednesday, May 19, 2010
hello FreeBSD...goodbye arch linux
well..tonyte i move to FreeBSD...if i like it, this shift is permanent, else i'll be back to arch (its like they say, they always come back)...but for now, its FreeBSD!! goodbye arch!
Friday, April 16, 2010
Scrotwm FTW!!
Okay so i moved to scrotwm from DWM...which i miss in a way, but what the hell ey, scrotwm is like dwm on drugs and has features that i was missing and wanted added but had to keep patching and all that jazz.I must say it does look pretty awesome and if any of you like dwm, you just have to give scrotwm a try.I'll post up pics of what mine looks like in a little while, a bit busy with perl ryt now..:)
Subscribe to:
Posts (Atom)