Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re: How could you make a script think it's running in its own directory?

by Lu. (Hermit)
on Mar 28, 2008 at 09:19 UTC ( [id://676935]=note: print w/replies, xml ) Need Help??


in reply to How could you make a script think it's running in its own directory?

You could also write a wrapper in bash or whatever shell you use and place that on your PATH.

Something on the lines of
#!/usr/bin/bash cd ~/other/BACKUP/ ./backup.pl
should do the trick.

Lu.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://676935]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others lurking in the Monastery: (6)
As of 2024-03-28 21:21 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found