-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
eduke32: (QOL) ignore case when check for user game data #3478
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
a5a617d
to
e5f2b58
Compare
(Make |
Sorry, this reply is a few years late. I think I would prefer to just check for the file in caps as well, rather than renaming user data. I suppose a mixed case filename is possible, but I would think unlikely. Unless there is a specific release with mixed case, which we could handle. |
Thinking about it, the check could be modified to use |
e5f2b58
to
2e92159
Compare
Am I overthinking or does it need all this:
Then Edit no this won't fail the download (I guess since it read stdin and not stderr) but still write error to screen (log?) if not suppress. So, either suppress with |
You can take advantage of the processing order of conditions: eg.
|
Posted on mobile, and had typos - fixed them. But hopefully this gives an idea :-) |
Making the directory before also seems fine, and makes it simpler. |
Changes look good thanks - I just had a thought, technically if someone made a folder called |
...in case user has old DOS files
b858141
to
6cd634e
Compare
if there is a folder there with that name, and this check fails, (ie. doesn't find a game data) then it tries to download shareware data and...what next?
Edit no i don't know how it'll work with the unzip command:
|
It's not a likely scenario - someone would have to make that folder. But maybe worth adding the |
I think I missed your point - as even with the -type f, it would then not find the directory and try and unpack. and the unzip might fail. I guess this could happen in the old logic too. Your code is safer without the |
Thank you! |
Yeah that's what I was getting at. Cheers! |
Sorry about that 😄. Thanks for the PR! |
...so shareware version is not downloaded unnecessarily, in case user has old DOS files in ALL CAPS. Add
rename
dependency. Modeled after wolf4sdl.