Skip to content

Initial implementation for persisting state #453

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

Merged
merged 9 commits into from
Mar 8, 2023

Conversation

CKolkey
Copy link
Member

@CKolkey CKolkey commented Feb 28, 2023

Adds a persistence layer for all switches/options. Users can disable this entirely via config remember_settings, it can be project-scoped (default) or global, and individual settings can be ignored by users, if they so desire.

I'm not sure how to expose the "reset" function right now, but it can be called directly if needed.

@CKolkey CKolkey mentioned this pull request Feb 28, 2023
@CKolkey CKolkey changed the title [wip] Initial implementation for persisting state Initial implementation for persisting state Mar 6, 2023
@CKolkey CKolkey marked this pull request as ready for review March 6, 2023 19:47
@ten3roberts
Copy link
Member

Project scoping as a default seems great.

Is there anything more you'd like to add, or should this be merged?

@CKolkey
Copy link
Member Author

CKolkey commented Mar 8, 2023

I'm happy with it if you are :)

Going to move M.state into the setup function. If that's good, then I'm done

@CKolkey
Copy link
Member Author

CKolkey commented Mar 8, 2023

That works nicely. Ok, good to go!

@ten3roberts ten3roberts merged commit c4068a2 into NeogitOrg:master Mar 8, 2023
@Fabian-programmer
Copy link
Contributor

Thank you for the feature.
I just have an annotation.
I'd say that a sane configuration is to disable it by default.
If someone force-pushes after a rebase. The force push setting is now active for the next commit.
For force-pushing I certainly want to opt-in instead of opt-out.

What do you think @CKolkey @ten3roberts

@CKolkey
Copy link
Member Author

CKolkey commented Mar 12, 2023

Yea, I think thats right. In fact, I have force push and force with lease disabled in my config.

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.

3 participants