fearthechris29 has asked for the wisdom of the Perl Monks concerning the following question:
Hi Monks, I'm writing a perl script to download a file from a url. The download part is ok but I need to change the permission of the file. I used chmod u+x <filename>, but every time I run my script I'm having this error: Bareword "u" not allowed while "strict subs" in use at download.pl line 40. Can you help me with this?</>
Here's my sample code
my $filename = "sample.pdf"; chmod u+x $filename;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: How to use chmod u +x in perl
by hdb (Monsignor) on Nov 25, 2013 at 08:34 UTC | |
by taint (Chaplain) on Nov 25, 2013 at 14:31 UTC | |
|
Re: How to use chmod u +x in perl
by Corion (Patriarch) on Nov 25, 2013 at 08:19 UTC | |
|
Re: How to use chmod u +x in perl
by GrandFather (Saint) on Nov 25, 2013 at 08:18 UTC | |
|
Re: How to use chmod u +x in perl
by daxim (Curate) on Nov 25, 2013 at 10:57 UTC | |
|
Re: How to use chmod u +x in perl
by Anonymous Monk on Nov 25, 2013 at 09:45 UTC | |
by Anonymous Monk on Nov 25, 2013 at 09:53 UTC | |
|
Re: How to use chmod u +x in perl
by taint (Chaplain) on Nov 25, 2013 at 14:14 UTC | |
by Tux (Canon) on Nov 25, 2013 at 16:47 UTC |