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

doc(installtaion): add documentation for flake inputs installation #12835

Open
aster-void opened this issue Feb 11, 2025 · 0 comments
Open

doc(installtaion): add documentation for flake inputs installation #12835

aster-void opened this issue Feb 11, 2025 · 0 comments
Labels
C-enhancement Category: Improvements

Comments

@aster-void
Copy link
Contributor

https://docs.helix-editor.com/package-managers.html#nixos

the use-site flake will look like this:

{
  inputs = {
    nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
    helix.url = "github:helix-editor/helix/master";
    helix.inputs.nixpkgs.follows = "nixpkgs";
  };

  outputs = { nixpkgs, ... } @ inputs:
  let
    system = "x86_64-linux";
    pkgs = nixpkgs.legacyPackages.${system};
  in {
    devShells.${system}.default = pkgs.mkShell {
      # use `inputs.helix.packages.${system}.default` as the package along with other packages from `pkgs`,
      # such as in nixos's `environment.systemPackages`, home-manager's `home.packages`, and devShell's `packages` (this example).
      packages = [
        inputs.helix.packages.${system}.default
      ];
    };
  };
  # how to add helix to substituters? copy-pasting helix flake's nixConfig doesn't seem to work...
  nixConfig = {};
}

also, it might be clearer to name this Nix, since using Nix isn't limited to NixOS.

@aster-void aster-void added the C-enhancement Category: Improvements label Feb 11, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-enhancement Category: Improvements
Projects
None yet
Development

No branches or pull requests

1 participant