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

Recognizing Existing or Prior Nix Installs (Curing) #126

Closed
1 of 3 tasks
Hoverbear opened this issue Dec 19, 2022 · 0 comments
Closed
1 of 3 tasks

Recognizing Existing or Prior Nix Installs (Curing) #126

Hoverbear opened this issue Dec 19, 2022 · 0 comments
Labels
enhancement New feature or request
Milestone

Comments

@Hoverbear
Copy link
Contributor

Hoverbear commented Dec 19, 2022

Some users have reported issues when trying to use this package on a system that had previously had Nix installed on it.

Currently, users will ideally get a planner error (for example, that a file or volume #217 already exists), but in some cases may get an install-time error.

We'd like to address this and make it easier.

This can break down into three major chunks of work:

  • Giving better error messages in cases where there are easily fixable problems the user can take. For example in Verify the apfs volume doesn't already exist before trying to create it #217 we tell the user the exact command to run.
  • Recognizing artifacts from previous installs, for example, an existing /nix/nix.conf with existing configuration which we can just modify.
    • In particular with /nix/nix.conf we would ideally have a way to 'merge' or 'upsert' the config to include features we toggle on.
    • There is an open question of what to do with these files that on uninstall, as the user might want us to remove /etc/nix.conf if they uninstall.
  • Offering some reasonable way to "cure" an existing install.

The last point is a bit wishy-washy so let's consider what that might look like:

  • A recognize subcommand which creates receipts for existing (possibly partial) installs and allows for use of uninstall later.
  • Some sort of doctor subcommand which essentially follows the recommended remedy steps codified in the first point
  • A "Cure" phase that happens between the plan and install phases, where the user is interactively prompted about running remedy steps.
  • Allowing actions to add "Cure" steps to the plan and presenting those inside of the plan summary for users.

TODO:

@Hoverbear Hoverbear added the enhancement New feature or request label Jan 9, 2023
@Hoverbear Hoverbear changed the title Generate valid receipts for existing Nix installs Recognizing Existing Nix Installs Feb 2, 2023
@Hoverbear Hoverbear pinned this issue Feb 7, 2023
@Hoverbear Hoverbear unpinned this issue Feb 7, 2023
@cole-h cole-h mentioned this issue Feb 22, 2023
18 tasks
@cole-h cole-h changed the title Recognizing Existing Nix Installs Recognizing Existing Nix Installs (Curing) Feb 28, 2023
@cole-h cole-h changed the title Recognizing Existing Nix Installs (Curing) Recognizing Existing or Prior Nix Installs (Curing) Feb 28, 2023
@Hoverbear Hoverbear added this to the v0.6.0 milestone Mar 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant