Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: How do you run a perl script using a custom perl build from an AppleScript?

by duelafn (Parson)
on May 27, 2017 at 21:29 UTC ( [id://1191387]=note: print w/replies, xml ) Need Help??


in reply to How do you run a perl script using a custom perl build from an AppleScript?

Some things I would try (I don't use a Mac so can't test):

1. Spawn bash explicitly (the default shell might not be getting all your environment variables):

# Not sure how quoting should work here, so fix if needed do shell script "bash -c /Users/stevied/bin/clean_desktop.pl"

2. Create a wrapper (e.g., clean_desktop.sh) which force-sets up perlbrew:

#!/bin/bash perlbrew use perl-5.16.0 # or whatever version/folder you are using /Users/stevied/bin/clean_desktop.pl

Then call the wrapper

do shell script "/Users/stevied/bin/clean_desktop.sh"

Good Day,
    Dean

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others romping around the Monastery: (5)
As of 2024-03-28 23:10 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found