From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 8A52413829C for ; Sun, 12 Jun 2016 17:04:55 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id EF1EDE0B6A; Sun, 12 Jun 2016 17:04:42 +0000 (UTC) Received: from smarthost01c.mail.zen.net.uk (smarthost01c.mail.zen.net.uk [212.23.1.5]) by pigeon.gentoo.org (Postfix) with ESMTP id C33D3E0B0B for ; Sun, 12 Jun 2016 17:04:41 +0000 (UTC) Received: from [82.69.80.10] (helo=peak.localnet) by smarthost01c.mail.zen.net.uk with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.80) (envelope-from ) id 1bC8oS-000496-GW for gentoo-user@lists.gentoo.org; Sun, 12 Jun 2016 17:04:40 +0000 From: Peter Humphrey To: gentoo-user@lists.gentoo.org Subject: Re: [gentoo-user] [A bit off-topic] Bash alias and & Date: Sun, 12 Jun 2016 18:04:39 +0100 Message-ID: <1683484.A4uHGnovoE@peak> User-Agent: KMail/4.14.10 (Linux/4.6.2-gentoo; KDE/4.14.20; x86_64; ; ) In-Reply-To: <199107d1-a2f3-b2a2-103c-287676c4f2d7@wht.com.au> References: <55ce9d76-0d0e-7529-38b4-950496cf9eb4@wht.com.au> <575D750D.4020007@gmail.com> <199107d1-a2f3-b2a2-103c-287676c4f2d7@wht.com.au> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-user@lists.gentoo.org Reply-to: gentoo-user@lists.gentoo.org MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" X-Originating-smarthost01c-IP: [82.69.80.10] X-Archives-Salt: e3fd67f4-19e8-4d4b-8eb1-c4204018e1f1 X-Archives-Hash: c10338a0465d23803b6979097c6ef766 Oi! I'm missing e-mails! On Sunday 12 Jun 2016 23:07:09 Andrew Lowe wrote: > On 06/12/16 22:43, Alan McKinnon wrote: I haven't received Alan's e-mail. > > On 12/06/2016 16:33, Nico Verrijdt wrote: > >> Hi Andrew, > >> > >> 2016-06-12 16:26 GMT+02:00 Andrew Lowe >> > >> >: > >> Hi all, > >> > >> A bit off topic here, but there are plenty of people who > >> > >> seem to know their shells back to front so here goes. > >> > >> I have set up a Win32 based development environment, > >> > >> bash/cc/ls/etc/etc, for 1st year Engineering students who have to > >> learn C on a command line. It's fine for me to remember to put the > >> & > >> at the end of the command when I fire up the editor but for them, > >> it's major angst. > >> > >> The first thing that comes to mind is an alias. Just off > >> > >> the top of my head I tried: > >> alias "npp=npp %1 &" > >> > >> Shouldn't this be: alias npp="npp %1 &" ? > >> > >> npp being the editor, but that didn't work. Is an alias the > >> best/easiest way to do this and if so, what would the syntax be, or > >> is there a better way? > >> > >> Any thoughts, greatly appreciated, > >> > >> Andrew > >> > >> Hope this helps, > >> Nico > > > > Or just tell them to remember to add the & at the end. > > With an alias what will they do when they don't want it? > > > > Or look at it this way: > > > > It's syntax, it's important. C is probably more syntax-critical than any > > other language around (binds to the right, anyone?) so what's the > > problem with requiring correct syntax on the command line as well? > > > > Obligatory disclaimer: I've recently had a bellyache full of dumb people > > who insist I put code when a human (themselves) belongs... > > Yes, I agree BUT, this is a "half subject" in a common first year of an > Engineering degree. These are people who will become > Civil/Mechanical/Electrical/Chemical Engineers and they have no desire > to learn programming. To put it bluntly, all they are interested in is > their car, getting drunk and trying to get a root - the order may vary, > but that is the top three priorities. Anything else is just too much to > think about. > > In reality, I'm doing this to make my life easier. As much as I tell > them to do something, write up documents that tell them what to do and > reiterate what they have to do, I still get the question "It's broken, > it won't do as I want...." > > Andrew > > p.s. Nico's point was a typo on my part in the email. Now that's a classic debug case - where are these messages being dropped? It's the second time I've noticed it in this list today. -- Rgds Peter