Skip to content

Commit f00ee62

Browse files
committed
chore(nix): adjust flake
1 parent d80baa1 commit f00ee62

File tree

1 file changed

+33
-10
lines changed

1 file changed

+33
-10
lines changed

flake.nix

Lines changed: 33 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,57 @@
11
{
22
description = "Moe-Counter Compatible Website Hit Counter";
3+
34
inputs = {
4-
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
55
flake-utils.url = "github:numtide/flake-utils";
66
nix-gleam.url = "github:arnarg/nix-gleam";
7+
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
8+
79
gitignore = {
810
url = "github:hercules-ci/gitignore.nix";
911
inputs.nixpkgs.follows = "nixpkgs";
1012
};
1113
};
12-
outputs = { self, nixpkgs, flake-utils, nix-gleam, gitignore, ... }:
13-
flake-utils.lib.eachDefaultSystem (system:
14+
15+
outputs =
16+
{
17+
flake-utils,
18+
gitignore,
19+
nix-gleam,
20+
nixpkgs,
21+
self,
22+
...
23+
}:
24+
flake-utils.lib.eachDefaultSystem (
25+
system:
1426
let
27+
inherit (gitignore.lib) gitignoreSource;
28+
1529
pkgs = import nixpkgs {
1630
inherit system;
31+
1732
overlays = [
1833
nix-gleam.overlays.default
1934
];
2035
};
21-
inherit (gitignore.lib) gitignoreSource;
2236
in
2337
{
24-
packages.default = pkgs.buildGleamApplication {
25-
src = gitignoreSource ./.;
26-
rebar3Package = pkgs.rebar3WithPlugins {
27-
plugins = with pkgs.beamPackages; [ pc ];
38+
packages = {
39+
default = pkgs.buildGleamApplication {
40+
src = gitignoreSource ./.;
41+
42+
rebar3Package = pkgs.rebar3WithPlugins {
43+
plugins = with pkgs.beamPackages; [ pc ];
44+
};
2845
};
46+
47+
mayu = self.packages.${system}.default;
2948
};
30-
devShell = pkgs.mkShell {
31-
buildInputs = [ pkgs.gleam pkgs.rebar3 ];
49+
50+
devShells.default = pkgs.mkShell {
51+
buildInputs = with pkgs; [
52+
gleam
53+
rebar3
54+
];
3255
};
3356
}
3457
);

0 commit comments

Comments
 (0)