RE: Scripting Best Practices
RE: Scripting Best Practices
- Subject: RE: Scripting Best Practices
- From: "John Williams" <email@hidden>
- Date: Thu, 11 Oct 2007 08:10:49 -0600
- Thread-topic: Scripting Best Practices
FWIW, I found a way to share script code that works pretty well. I'm using perl as the scripting language and just use the following:
# Call the actions that are shared with postupgrade
eval { require "$ARGV[0]/Contents/Resources/postactions.pl" };
This works fine.
The _javascript_ editing, though, is still annoying. :)
John
From: installer-dev-bounces+jwilliams=email@hidden on behalf of John Williams
Sent: Wed 10/10/2007 3:54 PM
To: email@hidden
Subject: Scripting Best Practices
Hi,
I have a couple questions regarding scripting in Distributions and regular Packages.
I have a lot of the same actions in my postinstall and postupgrade scripts. Is there a recommended way to share a single script file between the two?
For distributions, does anyone have any tips on easing the editing of the _javascript_s used in the distributions? Having to click Edit in the PackageMaker interface, then select TextWrangler (or whatever) from the script editor window and then clicking Edit again, make changes, close the temp file, go back to packagemaker and then clicking OK to make any change is getting really tedious. What I'd really like is a single _javascript_ file that defines all my global functions. I could then edit all my functions at once in a text editor.
Thanks
John Williams
Typefi Systems Pty Ltd
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Installer-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Installer-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden