Re: Shell script to detect OS version
Re: Shell script to detect OS version
- Subject: Re: Shell script to detect OS version
- From: Ted Thibodeau Jr <email@hidden>
- Date: Tue, 12 Jul 2005 21:10:58 -0400
* Chris Waldrip [2005/07/12 08:35 PM -0400] wrote:
> It looks like the best solution is to modify my shell script to
> run one part of the script if it's a release prior to 10.4.0,
> and another if its 10.4.0 or later. But there's the rub... I'm
> not tuned into how to detect the OS version from bash.
try sw_vers
or, if it's only running in the GUI already, you can *usually*
rely on the `uname -r` output to be in sync with the GUI space,
and just remember that `Darwin version minus four` will give you
the x.y in Mac OS X 10.x.y -- e.g., Darwin 8.2 corresponds to
Mac OS X 10.4.2; Darwin 7.8 corresponds to Mac OS X 10.3.8.
> Is there a way in Iceberg (btw, fantastic app Stépane) to run
> different scripts based on OS version? I see that there's a
> way to detect OS version from the Script requirements, but
> it's an all or nothing approach (do run if, don't run if).
No clue on this one.
Be seeing you,
Ted
--
A: Yes. http://learn.to/attribute
| Q: Are you sure?
| | A: Because it reverses the logical flow of conversation.
| | | Q: Why is top posting frowned upon?
Ted Thibodeau, Jr. // voice +1-781-273-0900 x32
Evangelism & Support // mailto:email@hidden
OpenLink Software, Inc. // http://www.openlinksw.com/
http://www.openlinksw.com/weblogs/uda/
OpenLink Blogs http://www.openlinksw.com/weblogs/virtuoso/
http://www.openlinksw.com/blog/~kidehen/
Universal Data Access and Virtual Database Technology Providers
_______________________________________________
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