Allow user to configure glob.globmatch()
to disable forced wcmatch.PATHNAME
globbing
#202
-
Hi, First, this is a great module and provides some great functionality for me! I have a request/question related to I'm trying to do this: I've tracked it down to the However, this causes a problem later, because this causes Is there a way that I can disable the force set of Thank you! |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 1 reply
-
So, let me ask, are you wanting to match Unix style paths on Windows? If so, maybe this helps: https://facelessuser.github.io/wcmatch/glob/#forceunix. You do not want to disable disable pathnames, that is what allows you to do paths vs just an fnmatch filename. Wcmatch adapts itself to the system you are working on, and if Windows, it will use Windows logic for paths. If you are using something that does not touch the filesystem though, like globmatch, you force a Unix or Windows logic and match arbitrary paths. EDIT: fixed typos |
Beta Was this translation helpful? Give feedback.
-
Oh, this totally worked for me! The paths I'm matching are Perforce paths, which aren't strictly Unix-style (leading |
Beta Was this translation helpful? Give feedback.
-
No problem. Sorry for the somewhat broken reply. I was replying on my phone, so some of the grammar is wrong. |
Beta Was this translation helpful? Give feedback.
So, let me ask, are you wanting to match Unix style paths on Windows? If so, maybe this helps: https://facelessuser.github.io/wcmatch/glob/#forceunix.
You do not want to disable disable pathnames, that is what allows you to do paths vs just an fnmatch filename.
Wcmatch adapts itself to the system you are working on, and if Windows, it will use Windows logic for paths. If you are using something that does not touch the filesystem though, like globmatch, you force a Unix or Windows logic and match arbitrary paths.
EDIT: fixed typos