problem double-clicking shell scripts
LuKreme
kremels at kreme.com
Tue May 22 19:47:27 PDT 2007
On 22-May-2007, at 18:08, Scott Ribe wrote:
>>> Shouldn't it be .command?
>> .sh is shorter
>
> Yes, but .command is known to the Finder to mean it's an executable
> that
> should be run when double-clicked.
Only if the file is actually marked as executable. creating a .sh
and marking it to 'open with terminal' then "Change All..." is a one
time price to pay, and I'm not even sure you have to do that. What
happens if you make a .sh file, mark it as executable, and double
click it? I mean, I know on my machine it runs in terminal, but who
knows how long ago I might have set that up, if I did. I think I
did, but if I recall correctly, it was because I installed SubEtha
Edit and it took over the .sh extension...
> By default on OS X client, double-clicking a .sh file opens it in
> TextEdit.
> Any other behavior from double-clicking a .sh file means that
> either the
> file has type/creator info, or some other option has been set up in
> Launch
> Services db either via Get Info's "Open with" option, or some
> installer, or
> some application's bundle claiming ownership, etc...
.sh is still shorter, although to be fair, I usually use no
extension. A no extension script file with the executable bit set
opens in terminal and executes, as it should.
--
Behind every great man there's a woman with a vibrator -- Hawkeye Pierce
More information about the MacOSX-admin
mailing list