On 9/11/18 6:24 PM, Gilmeh Serda wrote:
I think this is no different than RegEx matching, so the routine really
shouldn't be called glob() but the_regex_variations_opus_five().
Maybe your version should be called crippled_glob.
Globbing has a long history, longer than many of the people who
On Mon, Sep 10, 2018 at 3:05 PM, Thomas Jollans wrote:
from glob import glob
glob('test *')
> ['test comment', 'test [co]mment', 'test [fallacy]', 'test [comments]',
> 'test [comment] a']
glob('test [[]*')
> ['test [co]mment', 'test [fallacy]', 'test [comments]', 'test [comment]
Max Zettlmeißl via Python-list wrote:
>> glob('./Testfile [[]comment]*')
>>
>
> That is about the least correct working solution one could conceive.
> Of course your suggested "glob('./Testfile [[]comment]*')" works in
> the positive case, but pretty much comes down to a glob('./Testfile
>
On 10/09/18 14:40, Max Zettlmeißl via Python-list wrote:
On Sun, Sep 9, 2018 at 6:03 PM, Thomas Jollans wrote:
https://docs.python.org/3/library/glob.html#glob.escape demonstrates a way
of escaping that works:
glob('./Testfile [[]comment]*')
That is about the least correct working solution
On Sun, Sep 9, 2018 at 6:03 PM, Thomas Jollans wrote:
> On 09/09/2018 02:20 PM, Gilmeh Serda wrote:
>>
>>
>> # Python 3.6.1/Linux
>> (acts the same in Python 2.7.3 also, by the way)
>>
> from glob import glob
>>
>>
> glob('./Testfile *')
>>
>> ['./Testfile [comment] some text.txt']
>>
On Sun, Sep 9, 2018 at 2:20 PM, Gilmeh Serda
wrote:
>
> # Python 3.6.1/Linux
> (acts the same in Python 2.7.3 also, by the way)
>
from glob import glob
>
glob('./Testfile *')
> ['./Testfile [comment] some text.txt']
>
glob('./Testfile [comment]*')
> []
>
glob('./Testfile
On 09/09/2018 02:20 PM, Gilmeh Serda wrote:
# Python 3.6.1/Linux
(acts the same in Python 2.7.3 also, by the way)
from glob import glob
glob('./Testfile *')
['./Testfile [comment] some text.txt']
glob('./Testfile [comment]*')
[]
glob('./Testfile [comment? some text.*')
['./Testfile