filenames - Bash globbing - autoexpand for a few specific cases? -
I think the wildcard * (by itself) will expand in such a way that its meaning "All non-hidden files in the current folder" are prefixed to a period with hidden files.
In two useful cases I feel useful, but I do not know how to do it correctly:
-
How can you globe for All files in the current folder including hidden files, but
.or." -
How do you Globe for the ... "All hidden files (and hidden files only) in the current folder, but
.or.."?
to expand and answer the second part of your question For all files except and .. can be specified as such:
{. !!!] *, *} This dotglob shell option based on the case of your precise use, so that in default by * in bash Dotfile included:
$ shopt -s dotglob $ echo * .tst
Comments
Post a Comment