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

Multiple repos #15

Open
ghost opened this issue Apr 22, 2020 · 2 comments
Open

Multiple repos #15

ghost opened this issue Apr 22, 2020 · 2 comments
Labels
new feature New feature or request

Comments

@ghost
Copy link

ghost commented Apr 22, 2020

It would be great to manage some notes (e.g. for a project) in a separate root directory to prevent them from mixing into the other notes (and the other way around).

(Sorry for calling the directories repos, but I couldn't find a better name)

@iridakos
Copy link
Owner

Very good idea.

It needs some extra work to be done involving migration from current version (the repos will be placed where the categories are currently located).

Thanks for reporting, adding this to my todo list.

@iridakos iridakos added the new feature New feature or request label Apr 22, 2020
@ghost
Copy link
Author

ghost commented Apr 22, 2020

I think you don't even have to config the repos globally (this would make it more difficult to share the notes with others). Just a stup new-repo (or the existing stup configure), the configuration dialog (default location is pwd/stup), and you're done.

What needs a little thought is:

  • how to know to which repo to save (a switch like -l or --local for the project's repo could solve it)
  • how to know where's the repo (set explicitly via an argument or scan current directory and its parent directories for stup/ until it's found or / or $HOME is reached (where it's a nonsense for a project repo as there should be the "global" repo))

Also, maybe the default config file would have to be moved to ~/.stup. Only the default-category would have to be moved into the repo directory.

Oh, now I understood how you meant it. I thought of having the repo in the project directory, not in the global notes root. What you mean is already possible (maybe with some drawbacks)—I have some category/subcategory in my notes right now.

@iridakos iridakos assigned iridakos and unassigned iridakos Apr 24, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
new feature New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant