-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathflake.nix
35 lines (33 loc) · 939 Bytes
/
flake.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
{
description = "Nightly Typst with Typst LSP";
inputs.typst-lsp.url = "github:nvarner/typst-lsp";
inputs.typst.url = "github:typst/typst";
inputs.utils.url = "github:numtide/flake-utils";
inputs.nixpkgs.url = "github:nixos/nixpkgs/nixpkgs-unstable";
outputs = {
nixpkgs,
utils,
typst,
typst-lsp,
...
}:
utils.lib.eachDefaultSystem (system: let
typst-overlay = _self: _super: {
typst-lsp = typst-lsp.packages.${system}.default;
typst = typst.packages.${system}.default.overrideAttrs (_old: {
dontCheck = true;
});
};
pkgs = nixpkgs.legacyPackages.${system}.appendOverlays [typst-overlay];
typst-shell = pkgs.mkShell {
nativeBuildInputs = [
pkgs.typst-lsp
pkgs.typst
];
};
in {
devShells.default = typst-shell;
overlays.default = typst-overlay;
legacyPackages = pkgs;
});
}