swinters
swinters

Reputation: 347

Shell script to open an application and kill itself without closing application

I have a script to open chrome with some custom arguments:

/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --use-system-ssl --use-spdy=off

I need to run this and immediately close the process running it without killing chrome. Is there some way to do this?

Upvotes: 0

Views: 271

Answers (2)

Hubert Kario
Hubert Kario

Reputation: 22870

Just run it in background/fork:

#/bin/sh
/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --use-system-ssl --use-spdy=off &

Upvotes: 1

kchoose2
kchoose2

Reputation: 806

Say your script was run_chrome. Then you could do {run_chrome &} && disown;

Upvotes: 1

Related Questions