Mailing List Archive
tlug.jp Mailing List tlug archive tlug Mailing List Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]Re: [tlug] Rsync exclusion question
- Date: Mon, 15 Jun 2009 13:37:05 +0900
- From: John Fremlin <john@example.com>
- Subject: Re: [tlug] Rsync exclusion question
- References: <956ae5a90906100208k6ec1aeebnebb17f7534b8183a@example.com> <956ae5a90906100308l215adc81m1dcfbb54dc826472@example.com> <d8fcc0800906100527p59d4d548v42999d96e7ad066c@example.com> <956ae5a90906100547i2e610cct42b8b075c50b6d6@example.com> <d8fcc0800906100614s4c909d0fj8091e3bfe9926c18@example.com> <4A30D148.1090004@example.com> <d8fcc0800906110258y553b9712hcb55c5a3ed4b6d69@example.com> <956ae5a90906110321k54545d53rb3cbae6f7044aaa0@example.com> <d8fcc0800906110355h21af4adtce1ddc3d95164988@example.com> <4A31BD61.2000900@example.com> <d8fcc0800906120209j6aeb6fbg2aafcc59648762b3@example.com>
- User-agent: Thunderbird 2.0.0.21 (X11/20090409)
Josh Glover wrote:Of course one *should* understand the basics of interpolation in any language one uses. But the Best Practice is about avoiding interpolation altogether unless you *know* you want it in a string, and then understanding the rules as they apply to that string.How is interpolation relevant to the (alleged) difference between "*.leases" and '*.leases'?I've seen old Unix hands tripped up by shell interpolation many times.It can lead to very serious bugs so I don't see how there are any excuses for being muddled up.I've seen excellent C programmers mix up = and == but they at least had the decency to feel extremely embarrassed by it.Stephen J. Turnbull wrote: > Josh Glover writes: > > Me neither, but I think it has to do with how Doug is invoking his > > script. > > I find this is invariably because I (a) wrote a script or shell > function for unit testing, and quotes are being stripped there, or (b) > some command I thought was either a shell built-in or a real program > was replaced by a shell script, usually by a distro trying to make > something like the autofools more "user-friendly". Excellent point.PARAMETERS [...] Positional ParametersWhat's this got to do with anything? [...]Special Parameters The shell treats several parameters specially. These parameters may only be referenced; assignment to them is not allowed. * Expands to the positional parameters, starting from one. When the expansion occurs within double quotes, it expands to a single word with the value of each parameter separated by the first character of the IFS special variable. That is, "$*" is equivalent to "$1c$2c...", where c is the first character of the value of the IFS variable. If IFS is unset, the parameters are separated by spaces. If IFS is null, the parameters are joined without intervening separators. But what Doug was doing shouldn't have triggered any magic with *, AFAICT.Yes, because that part of the manpage is talking about $* and "$*" I think?
- References:
- [tlug] [TLUG] Rsync exclusion question
- From: Doug McLean
- Re: [tlug] [TLUG] Rsync exclusion question
- From: Doug McLean
- Re: [tlug] [TLUG] Rsync exclusion question
- From: Josh Glover
- Re: [tlug] [TLUG] Rsync exclusion question
- From: Doug McLean
- Re: [tlug] [TLUG] Rsync exclusion question
- From: Josh Glover
- Re: [tlug] Rsync exclusion question
- From: John Fremlin
- Re: [tlug] Rsync exclusion question
- From: Josh Glover
- Re: [tlug] Rsync exclusion question
- From: Doug McLean
- Re: [tlug] Rsync exclusion question
- From: Josh Glover
- Re: [tlug] Rsync exclusion question
- From: John Fremlin
- Re: [tlug] Rsync exclusion question
- From: Josh Glover
Home | Main Index | Thread Index
- Prev by Date: [tlug] Call for presenters - July 11th technical meeting
- Next by Date: [tlug] Linux habits in Windows world
- Previous by thread: Re: [tlug] Rsync exclusion question
- Next by thread: Re: [tlug] Rsync exclusion question
- Index(es):
Home Page Mailing List Linux and Japan TLUG Members Links