[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [bug #51309] Determination of a file list from a single folder witho
SF Markus Elfring
Re: [bug #51309] Determination of a file list from a single folder without changing the working directory
Mon, 26 Jun 2017 20:31:01 +0200
Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.0
> MY_FILES=$(notdir $(wildcard somedir/*.ext))
I agree that this algorithm can work. But it does not fit to my imaginations
for efficient data processing.
If the desired directory on which a file filter should be applied
could be selected before, the file names would not contain references
to this directory and another function call is therefore unnecessary
to remove it from the returned list elements.
The difference can eventually better seen by an approach like the following.
~/Projekte> ls Bau/*txt
~/Projekte> cd Bau && ls *txt
I would like to achieve the second list result without using
the command “cd” before.