Skip to content

Commit

Permalink
feat: nix flake (#59)
Browse files Browse the repository at this point in the history
  • Loading branch information
meowgorithm authored Apr 5, 2024
1 parent 1899c76 commit c8ae034
Show file tree
Hide file tree
Showing 4 changed files with 92 additions and 0 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,4 @@
!test/golden/**/*.svg
!test/golden/**/*.png
!examples/*.svg
/result
6 changes: 6 additions & 0 deletions default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{pkgs}:
pkgs.buildGoModule {
name = "freeze";
src = ./.;
vendorHash = "sha256-6++AGNKse/cBg5TAybnoiuvgMf8KjXJ37fVwFNDK4Ic=";
}
61 changes: 61 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
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
{
description = "A tool for generating images of code and terminal output";

inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-23.11";
flake-utils.url = "github:numtide/flake-utils";
};

outputs = {
self,
nixpkgs,
flake-utils,
}:
flake-utils.lib.eachDefaultSystem (system: let
pkgs = import nixpkgs {inherit system;};
in {
packages.default = import ./default.nix {inherit pkgs;};
})
// {
overlays.default = final: prev: {
freeze = import ./default.nix {pkgs = final;};
};
};
}

0 comments on commit c8ae034

Please sign in to comment.