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

Remember the last open project #52

Open
MichalZalecki opened this issue Nov 27, 2020 · 2 comments · May be fixed by #53
Open

Remember the last open project #52

MichalZalecki opened this issue Nov 27, 2020 · 2 comments · May be fixed by #53

Comments

@MichalZalecki
Copy link
Contributor

Is your feature request related to a problem? Please describe.

Each time I restart Hetty I have to activate the project.

Describe the solution you'd like

I would like my last project to be selected without any additional action. I think this is safe enough to make this a new default behavior. The question is, where to store this information?

My initial idea is to save it in a simple text file in the projPath e.g. ~/.hetty/projects/last_open or something like that.

The other idea that might be worth considering is to have a project-agnostic database file e.g. ~/.hetty/Config.db where all settings that arent related to any particular project can be stored.

Let me know what you think, I'm happy to work on it.

@dstotijn
Copy link
Owner

I think auto opening the last project at start isn't necessarily expected default behaviour (I guess this is a bit subjective). As far as I know other similar software doesn't do this. I do think there's value in having some control over opening a project at startup. I would opt to introduce a flag to indicate the project (new or existing) that you'd like to open by name. Example usage would be:

hetty --project foobar

The idea you mentioned of project-agnostic settings could be interesting to explore in the future if there's more user settings (e.g. proxy defaults, UI/UX settings) we'd want to persist. But I would say it's best to hold off a bit longer on that until we have more "core" features in place.

@MichalZalecki
Copy link
Contributor Author

A command-line argument also works for me. I'll prepare a PR 👌

@MichalZalecki MichalZalecki linked a pull request Dec 2, 2020 that will close this issue
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 a pull request may close this issue.

2 participants