From 9edcc925641218b074d13ad2d611138a7cfdc9c2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robin=20B=C3=A4rtschi?= Date: Sun, 9 Mar 2025 12:44:50 +0100 Subject: [PATCH] support nix-build run `nix-build nix` to build without flakes --- nix/default.nix | 4 ++++ nix/package.nix | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-) create mode 100644 nix/default.nix diff --git a/nix/default.nix b/nix/default.nix new file mode 100644 index 0000000..8f111e5 --- /dev/null +++ b/nix/default.nix @@ -0,0 +1,4 @@ +# ml2 ts=2 sts=2 sw=2 + +with import {}; +callPackage ./package.nix {} diff --git a/nix/package.nix b/nix/package.nix index 14f6846..4404d39 100644 --- a/nix/package.nix +++ b/nix/package.nix @@ -1,7 +1,8 @@ # ml2 ts=2 sts=2 sw=2 -{buildGoModule, version}: buildGoModule { +{buildGoModule, version ? "HEAD"}: buildGoModule { pname = "tt"; inherit version; + # In 'nix develop', we don't need a copy of the source tree # in the Nix store. src = ./..;