Skip to content

Commit

Permalink
add: rnix-lsp overlays
Browse files Browse the repository at this point in the history
Add `rnix-lsp` `overlays` to the flake outputs, in order to be directly
consumed by other flakes.

Provides 2 overlays:
- default: with package named `rnix-lsp`, so people can overwrite their
  existing configuration
- nightly: with package named `rnix-lsp-nightly`, so people can opt in
  to this package on a case-by-case basis

Also for now still uses the `overlay` attribute, for backwards
compatibility, is that needed?

fixes: nix-community#77
  • Loading branch information
a-kenji committed Apr 7, 2022
1 parent 4d1024c commit 72388c9
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 3 deletions.
3 changes: 1 addition & 2 deletions flake-compat.nix
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ let
url = "https://github.com/edolstra/flake-compat/archive/12c64ca55c1014cdc1b16ed5a804aa8576601ff2.tar.gz";
sha256 = "0jm6nzb83wa6ai17ly9fzpqc40wg1viib8klq8lby54agpl213w5";
};
in
(import flake-compat {
in (import flake-compat {
src = ./.;
})
14 changes: 13 additions & 1 deletion flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -35,5 +35,17 @@
drv = packages.rnix-lsp;
};
defaultApp = apps.rnix-lsp;
});
})
//
rec {
overlays = {
default = final: prev: rec {
rnix-lsp = self.packages.${prev.system}.rnix-lsp;
};
nightly = final: prev: rec {
rnix-lsp-nightly = self.packages.${prev.system}.rnix-lsp;
};
};
overlay = overlays.default;
};
}

0 comments on commit 72388c9

Please sign in to comment.