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

Interactive mode #8

Open
metov opened this issue Sep 6, 2021 · 0 comments
Open

Interactive mode #8

metov opened this issue Sep 6, 2021 · 0 comments

Comments

@metov
Copy link
Owner

metov commented Sep 6, 2021

It would be nice if we could install interactively. For example, something like:

$ dots install . -i
DEBUG: Starting interactive mode...
Descend into folder ./foo? N
DEBUG: Skipping ./foo
Descend into folder ./bar? Y
Install ./bar/baz/spec.yaml? N
DEBUG: Skipping ./bar/baz/spec.yaml
Install ./bar/xyz/spec.yaml? Y
DEBUG: Installing ./bar/xyz/spec.yaml

This targets the use case where the user wants to install some, but not all, of their many specs. This is already kind of handled by the directory structure - for example if you have some dotfiles that should only be installed on machine A, and some that should only be on machine B, you can do dots install ./common/ && dots install ./machine-a/ or dots install ./common/ && dots install ./machine-b/ respectively. Obviously this requires you to pre-sort them into directories, so it's a good fit for consistently recurring situations (such as two different computers). However, there is also the case of adhoc subsetting for troublshooting and so on, in which case it's tedious to just organize everything into folders just for that one subset - this is where the interactive mode would help.

Technically, it would be easy to implement the interactive mode for both install and check. However check is intended to be non-destructive, so there doesn't seem to be a use case for letting the user interactively choose which specs to check. If the user did write some check: commands that have side effects, that seems like user error. I think therefore it would be less confusing to implement interactive mode only for install. Not like it wouldn't be easier to change it later anyhow.

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

1 participant