Forums
New posts
Articles
Product Reviews
Policies
FAQ
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Menu
Log in
Register
Install the app
Install
Forums
macOS & iOS Developer Playground
macOS - Development and Darwin
PackageMaker PreFlight question
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="jonculloty" data-source="post: 889822" data-attributes="member: 116049"><p>Hello,</p><p></p><p>I have a very small script that I want to run as a pre-flight step in packagemaker.... its used to kill a specific process.</p><p></p><p><span style="font-family: 'Courier New'"></span></p><p><span style="font-family: 'Courier New'">#!/bin/ksh</span></p><p><span style="font-family: 'Courier New'">pid=`ps -e | egrep nameofmyapp | egrep -v egrep | awk '{print $1}`</span></p><p><span style="font-family: 'Courier New'">kill -TERM ${pid}</span></p><p><span style="font-family: 'Courier New'"></span></p><p></p><p>When I do "Build and Run" it throws the message "Install Failed". By trial and error I've figured out that it does not like the kill line. Running the script standalone in a terminal works perfectly. Anyone have any ideas whats going on here, I'm puzzled.</p><p></p><p>Thanks,</p><p>Jonathan</p></blockquote><p></p>
[QUOTE="jonculloty, post: 889822, member: 116049"] Hello, I have a very small script that I want to run as a pre-flight step in packagemaker.... its used to kill a specific process. [FONT="Courier New"] #!/bin/ksh pid=`ps -e | egrep nameofmyapp | egrep -v egrep | awk '{print $1}` kill -TERM ${pid} [/FONT] When I do "Build and Run" it throws the message "Install Failed". By trial and error I've figured out that it does not like the kill line. Running the script standalone in a terminal works perfectly. Anyone have any ideas whats going on here, I'm puzzled. Thanks, Jonathan [/QUOTE]
Verification
Post reply
Forums
macOS & iOS Developer Playground
macOS - Development and Darwin
PackageMaker PreFlight question
Top