Skip to content

Commit

Permalink
feat: Add a nix flake (#37)
Browse files Browse the repository at this point in the history
  • Loading branch information
Pacman99 committed Jun 24, 2022
1 parent 204f610 commit 9b9ce2a
Show file tree
Hide file tree
Showing 4 changed files with 126 additions and 1 deletion.
4 changes: 4 additions & 0 deletions .editorconfig
Expand Up @@ -23,6 +23,10 @@ insert_final_newline = false
charset = utf-8
trim_trailing_whitespace = true

[*.nix]
charset = utf-8
indent_size = 2

[.gitignore]
end_of_line = lf
insert_final_newline = false
Expand Down
5 changes: 4 additions & 1 deletion .gitignore
Expand Up @@ -11,4 +11,7 @@
daemon.toml

# Mac Files
.DS_Store
.DS_Store

# Nix build results
result
94 changes: 94 additions & 0 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

24 changes: 24 additions & 0 deletions flake.nix
@@ -0,0 +1,24 @@
{
inputs = {
crane.url = "github:ipetkov/crane";
utils.url = "github:numtide/flake-utils";
};

outputs = {
self,
crane,
utils,
...
}: let
supportedSystems = ["x86_64-linux" "x86_64-darwin" "aarch64-linux"];
in
utils.lib.eachSystem supportedSystems
(
system: {
packages.scrolls = crane.lib.${system}.buildPackage {
src = self;
};
packages.default = self.packages.${system}.scrolls;
}
);
}

0 comments on commit 9b9ce2a

Please sign in to comment.