M
Marcin Kulisz
hi all,
today is my first day with ruby and I'm trying to rewrite a few of my
scripts from perl to ruby & it's not too easy. can anyone help me with
script below. I've done a few thinks but when one is working another
don't.
today is my first day with ruby and I'm trying to rewrite a few of my
scripts from perl to ruby & it's not too easy. can anyone help me with
script below. I've done a few thinks but when one is working another
don't.
#!/usr/bin/perl -w
$usr=$ARGV[0];
$id=`cat /etc/passwd|grep $usr|cut -d\":\" -f3`;
if ($id>=1000){
$text=`finger $usr`;
$text=~s/\n/\<br\>/g;
print $text;
} else {
print "wal się na ryj złodzieju";
}