Skip to content
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

Quick way to reload file #124

Closed
sammko opened this issue Apr 30, 2021 · 2 comments
Closed

Quick way to reload file #124

sammko opened this issue Apr 30, 2021 · 2 comments
Labels
feature A new feature
Milestone

Comments

@sammko
Copy link

sammko commented Apr 30, 2021

I don't see a way to quickly reload the contents of a file, other than opening it anew, which loses the viewport position. A reload function (mapped to F5 or Ctrl+R for example) would be useful.

Maybe also an opt-in autoreload feature, which would detect changes (inotify etc) and reload the file? Or maybe prompt for a reload?

Thanks for this tool by the way, I've always missed a good non-bloated hex editor.

@solemnwarning solemnwarning added the feature A new feature label May 1, 2021
@solemnwarning
Copy link
Owner

I hadn't gotten round to dealing with the file changing under the editor yet as it's a bit awkward - the file isn't actually loaded into memory whole by design*; blocks get paged in and out as necessary - in effect it's kind of reloading the file continuously, except blocks which have been modified.

There are things I could do here - lock the whole file in memory if it's small enough, or warn if the file is changed on disk and refuse to page in unloaded blocks after an external change. Any ideas welcome :)

@solemnwarning
Copy link
Owner

Merged in 955ad36.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature A new feature
Projects
None yet
Development

No branches or pull requests

2 participants