[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Help-bash] Filename Expansion: Find Utility vs Bash Shell Pattern M
From: |
Stephane Chazelas |
Subject: |
Re: [Help-bash] Filename Expansion: Find Utility vs Bash Shell Pattern Matching |
Date: |
Thu, 18 Jun 2015 14:40:23 +0100 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
2015-06-17 11:50:24 -0700, Michael Convey:
> Chet and Greg, thanks for your follow-up explanations and additional links.
> I will read them and learn each program's features one-by-one as suggested,
> while still trying to maintain a big picture view. I find the lack of
> standardization unnecessarily complex and frustrating. I believe this kind
> of complexity is why many people become exasperated and give up on Linux. I
> will persevere, but I hope standardization will prevail in the long run.
[...]
Those patterns are clearly specified in POSIX. Some
implementations have extensions. But those extensions will
generally not get in the way if you don't use them.
*.txt as a pattern (like in "case" constructs or as in find's
-name or -path operators, or arguments to pax) will work the
same everywhere on valid input.
How shell quoting interfers with the processing of those
patterns both for "case" and "globs" is also clearly specified
(except maybe in some corner cases).
Now, many shells have extensions and that's good. That's called
progress. It happens in and outside the Unix world just the
same. The Unix world is lucky enough to have a standard that
most players follow which means you can rely on a common subset
when portabiltiy is a concern.
Also note that Linux doesn't deal in any way with glob/fnmatch
patterns. That's entirely in the domain of applications. Those
applications work the same whether there's a Linux or FreeBSD or
Illumos kernel. Most of them run on Windows and OS/X as well
(OS/X being a (certified for some of the version) Unix, and
some versions of MS Windows having been POSIX conformant as
well).
Not to mention that those globs (which have been in Unix for
over 45 years old) are universally found including in MS-DOS for
decades.
--
Stephane
- [Help-bash] Filename Expansion: Find Utility vs Bash Shell Pattern Matching, Michael Convey, 2015/06/16
- Re: [Help-bash] Filename Expansion: Find Utility vs Bash Shell Pattern Matching, Greg Wooledge, 2015/06/17
- Re: [Help-bash] Filename Expansion: Find Utility vs Bash Shell Pattern Matching, Chet Ramey, 2015/06/17
- Re: [Help-bash] Filename Expansion: Find Utility vs Bash Shell Pattern Matching, Michael Convey, 2015/06/17
- Re: [Help-bash] Filename Expansion: Find Utility vs Bash Shell Pattern Matching, Chet Ramey, 2015/06/17
- Re: [Help-bash] Filename Expansion: Find Utility vs Bash Shell Pattern Matching, Chet Ramey, 2015/06/17
- Re: [Help-bash] Filename Expansion: Find Utility vs Bash Shell Pattern Matching, Michael Convey, 2015/06/17
- Re: [Help-bash] Filename Expansion: Find Utility vs Bash Shell Pattern Matching, Dennis Williamson, 2015/06/17
- Re: [Help-bash] Filename Expansion: Find Utility vs Bash Shell Pattern Matching,
Stephane Chazelas <=
- Re: [Help-bash] Filename Expansion: Find Utility vs Bash Shell Pattern Matching, Greg Wooledge, 2015/06/18
- Re: [Help-bash] Filename Expansion: Find Utility vs Bash Shell Pattern Matching, Stephane Chazelas, 2015/06/18
Re: [Help-bash] Filename Expansion: Find Utility vs Bash Shell Pattern Matching, Michael Convey, 2015/06/17
Re: [Help-bash] Filename Expansion: Find Utility vs Bash Shell Pattern Matching, Stephane Chazelas, 2015/06/17