From: Thorsten Kampe <thorsten@thorstenkampe.de>
To: cygwin@cygwin.com
Subject: Re: Portable shell code between Cygwin and Linux
Date: Tue, 02 Aug 2011 20:05:00 -0000 [thread overview]
Message-ID: <j19l9a$s9b$1@dough.gmane.org> (raw)
In-Reply-To: <4E381A7C.2000000@cs.umass.edu>
* Eliot Moss (Tue, 02 Aug 2011 11:40:44 -0400)
> On 8/2/2011 8:24 AM, Sebastien Vauban wrote:
> > Thorsten Kampe wrote:
> >> * Sebastien Vauban (Mon, 01 Aug 2011 08:46:52 +0200)
> >>> My goal is to have just 1 alias that would work both under Win32
> >>> (Cygwin) and Ubuntu
> >>
> >> Why don't have simply put your alias definitions in if [[ $OSTYPE =
> >> cygwin ]]; then else"?
> >
> > Because I really want one single definition which could work on
> > every system I'm using.
[...]
> The suggestion to use a few conditionals that look at the which OS
> you're on does not involve continued tweaking. Once you have the right
> file, it works everywhere (for which you have provided suitable cases)
> using the exact same file. It's just that different parts get executed
> on different platforms. It's not as elegant as achieving an
> arrangement with no conditionals, but it's practical and flexible.
Couldn't have said it better. Cygwin is not Linux and you just can't
ignore the differences. For example I have different aliases for netstat
and ps on Linux and on Windows. They just don't have the same options.
Thorsten
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
next prev parent reply other threads:[~2011-08-02 20:05 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-07-29 19:15 Sebastien Vauban
2011-07-29 19:45 ` Larry Hall (Cygwin)
2011-08-01 6:40 ` Sebastien Vauban
2011-07-29 19:47 ` Eliot Moss
2011-08-01 6:45 ` Sebastien Vauban
2011-07-29 20:17 ` Corinna Vinschen
2011-07-30 12:20 ` Andrey Repin
2011-08-01 6:50 ` Sebastien Vauban
2011-08-01 7:28 ` Csaba Raduly
2011-08-02 11:58 ` Sebastien Vauban
2011-08-02 12:36 ` Sebastien Vauban
2011-08-05 16:05 ` Andrey Repin
2011-08-08 1:16 ` Sven Köhler
2011-08-08 2:07 ` Eliot Moss
2011-08-08 22:17 ` Gary Johnson
2011-08-08 8:20 ` Andrey Repin
2011-08-08 9:11 ` Sven Köhler
2011-08-08 14:27 ` Eliot Moss
2011-08-01 7:00 ` Sebastien Vauban
2011-08-01 7:44 ` Corinna Vinschen
2011-08-02 12:11 ` Sebastien Vauban
2011-08-02 12:23 ` Sebastien Vauban
2011-08-02 14:37 ` Corinna Vinschen
2011-08-01 9:21 ` Thorsten Kampe
2011-08-02 12:25 ` Sebastien Vauban
2011-08-02 15:41 ` Eliot Moss
2011-08-02 20:05 ` Thorsten Kampe [this message]
2011-08-02 20:45 ` Christopher Faylor
2011-08-03 16:23 ` Andy Hall
2011-08-08 1:20 ` Sven Köhler
2011-08-08 13:41 ` Eric Blake
2011-08-10 12:03 ` Sven Köhler
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='j19l9a$s9b$1@dough.gmane.org' \
--to=thorsten@thorstenkampe.de \
--cc=cygwin@cygwin.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).