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

feature: delete current dir session #107

Merged
merged 2 commits into from
Jan 20, 2024
Merged

feature: delete current dir session #107

merged 2 commits into from
Jan 20, 2024

Conversation

adrianord
Copy link
Contributor

Fixes: #104

Adds a delete_current_dir_session command.

A caveat to this command is that if autosave is turned on, it will end up saving the session again on exit. A simple work around for this is to delete all the buffers (e.g. :bufdo bd) before running the command.
I think there may be a way around this, but feel it's out of scope of this PR.

@Shatur Shatur merged commit 5bc6aa5 into Shatur:master Jan 20, 2024
1 of 2 checks passed
@adrianord adrianord mentioned this pull request Jan 20, 2024
@pmatulis
Copy link

If the new command won't effectively work without deleting all buffers beforehand when autosave is enabled why not include a check for this situation and do what's needed? Or maybe include an option to enable that extra behavior?

@adrianord
Copy link
Contributor Author

@pmatulis I wanted to at least get the command out there to use.

Unfortunately getting it to work with autosave is a bit more tricky because we need to persist that we ran the command so when we exit and run autosave we know not to save. I'm sure it's possible, but I'm not a lua expert and wanted to at least get the command out. I might plug along later on this though, because I kind of want it, too.

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

Successfully merging this pull request may close these issues.

[RFE] Delete current session
3 participants