ImHex
ImHex copied to clipboard
[Bug] Confusing behaviour when ImHex is ran from a terminal
Operating System
Linux
What's the issue you encountered?
If running from the terminal, attempting to open a file that does not exist will result in ImHex trying to open that file and failing to do so, resulting in a window that looks like this:
Reloading the file in ImHex just closes the file.
Additionally, if one was to try running ImHex with options passed, ImHex will treat those options as the name of the file it's supposed to be opening. Admittedly this part isn't necessarily a bug, but it is confusing behaviour none-the-less. If I run ImHex with the command imhex --version
I'd expect ImHex to output it's version or at least tell me that the option was unrecognized, but instead ImHex opens a non-existent file named --version
.
How can the issue be reproduced?
Assuming there is no file named non-existent.file
, simply run the following in a terminal: imhex non-existent.file
ImHex Version
1.27.1 f435191
ImHex Build Type
- [ ] Nightly or built from sources
Installation type
AUR on both imhex-git and imhex-bin
Additional context?
No response
Hey @WerWolv, what do you think the correct behaviour should be, here ? Personally I think it should open a view like "Create new file" button, but with the filename instead of "Unsaved file" (vscode has this behaviour)
As for options like --version
or --help
, well.. I think it should try to treat them ofc
We are going to work on terminal arguments. This will require some work. design discussed in discord: https://discord.com/channels/789833418631675954/789833418631675957/1088951410806235146