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

Automatically refresh the Source Control view #199

Closed
NomarCub opened this issue Mar 1, 2022 · 4 comments
Closed

Automatically refresh the Source Control view #199

NomarCub opened this issue Mar 1, 2022 · 4 comments

Comments

@NomarCub
Copy link

NomarCub commented Mar 1, 2022

This could definitely be done when the plugin's own related commands are executed.
There are also hooks in Obsidian, that could refresh the Source Control view, if it is open - like moving, renaming, opening, closing files and folders (even hooks for editing them, but I'm not sure). These specific ones wouldn't even necessitate looking for changes in the whole vault, just the affected files.
Another solution is handling it like DataView (also VSCode and others), and refreshing periodically, with the user potentially being able to adjust the refresh interval.

@Vinzent03
Copy link
Collaborator

It already watches for metadata changes. So it refreshes on file delete, edits, etc. But if debounces them for 5 minutes. So it refreshes after 5 minutes. That's definitely too high. Will add a setting to disable it, because of some Mac OS issues. #69

@NomarCub
Copy link
Author

NomarCub commented Sep 6, 2022

Changes can take over 8 seconds to show up. Could the timer be made configurable? How resource intensive is it with the Mac issue solved?

@Vinzent03
Copy link
Collaborator

It's currently debounced to 7 seconds. So you have to stop editing for 7 seconds. iirc somebody reported lags while typing. Will add a setting...

@Vinzent03
Copy link
Collaborator

It's now configurable in the latest release.

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

No branches or pull requests

2 participants