From 14dd983e5a6c52de219c424889ada006957275a3 Mon Sep 17 00:00:00 2001 From: pilz <48645439+pilz0@users.noreply.github.com> Date: Thu, 26 Feb 2026 09:50:14 +0100 Subject: [PATCH 1/5] feat: add nix flake --- .gitignore | 1 + flake.lock | 61 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ flake.nix | 37 +++++++++++++++++++++++++++++++++ 3 files changed, 99 insertions(+) create mode 100644 .gitignore create mode 100644 flake.lock create mode 100644 flake.nix diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..e2f5dd2 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +result \ No newline at end of file diff --git a/flake.lock b/flake.lock new file mode 100644 index 0000000..5bbb065 --- /dev/null +++ b/flake.lock @@ -0,0 +1,61 @@ +{ + "nodes": { + "flake-utils": { + "inputs": { + "systems": "systems" + }, + "locked": { + "lastModified": 1731533236, + "narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=", + "owner": "numtide", + "repo": "flake-utils", + "rev": "11707dc2f618dd54ca8739b309ec4fc024de578b", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "flake-utils", + "type": "github" + } + }, + "nixpkgs": { + "locked": { + "lastModified": 1771848320, + "narHash": "sha256-0MAd+0mun3K/Ns8JATeHT1sX28faLII5hVLq0L3BdZU=", + "owner": "nixos", + "repo": "nixpkgs", + "rev": "2fc6539b481e1d2569f25f8799236694180c0993", + "type": "github" + }, + "original": { + "owner": "nixos", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "root": { + "inputs": { + "flake-utils": "flake-utils", + "nixpkgs": "nixpkgs" + } + }, + "systems": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/flake.nix b/flake.nix new file mode 100644 index 0000000..f145f45 --- /dev/null +++ b/flake.nix @@ -0,0 +1,37 @@ +{ + inputs = { + nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; + flake-utils.url = "github:numtide/flake-utils"; + }; + + outputs = { self, nixpkgs, flake-utils }: { + overlays.default = final: prev: { + proserver-cli = final.callPackage + ({ stdenv, pkgs, ... }: + stdenv.mkDerivation { + src = ./.; + pname = "proserver-cli"; + version = "1.0.1"; + } + ) + { }; + }; + } // + (flake-utils.lib.eachDefaultSystem (system: + let + pkgs = import nixpkgs { + system = system; + overlays = [ self.overlays.default ]; + }; + lib = nixpkgs.lib; + in + { + packages = { + proserver-cli = pkgs.writeScriptBin "proserver-cli" (builtins.readFile ./proserver); + default = self.packages.${system}.proserver-cli; + }; + formatter = pkgs.nixpkgs-fmt; + + } + )); +} From b4365b33eff5bd8a17ea15fbd51e755b0beb1066 Mon Sep 17 00:00:00 2001 From: pilz <48645439+pilz0@users.noreply.github.com> Date: Thu, 26 Feb 2026 09:51:38 +0100 Subject: [PATCH 2/5] chore: update readme --- README.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/README.md b/README.md index 018c4d7..1a99940 100644 --- a/README.md +++ b/README.md @@ -19,3 +19,8 @@ proserver 9999 # or vpro 9999 ``` + +## Nix +```bash +nix run github.com:punktDe/proserver-cli +``` \ No newline at end of file From 874495123360bce496478816bec32da011afdca3 Mon Sep 17 00:00:00 2001 From: Pilz <48645439+pilz0@users.noreply.github.com> Date: Thu, 26 Feb 2026 10:48:50 +0100 Subject: [PATCH 3/5] Update README.md Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 1a99940..da4215d 100644 --- a/README.md +++ b/README.md @@ -22,5 +22,5 @@ vpro 9999 ## Nix ```bash -nix run github.com:punktDe/proserver-cli +nix run github:punktDe/proserver-cli ``` \ No newline at end of file From a58e2e22f0c79c2818585445df5b2004efe824eb Mon Sep 17 00:00:00 2001 From: Pilz <48645439+pilz0@users.noreply.github.com> Date: Thu, 26 Feb 2026 10:48:59 +0100 Subject: [PATCH 4/5] Update flake.nix Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --- flake.nix | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) diff --git a/flake.nix b/flake.nix index f145f45..4e30a45 100644 --- a/flake.nix +++ b/flake.nix @@ -4,24 +4,11 @@ flake-utils.url = "github:numtide/flake-utils"; }; - outputs = { self, nixpkgs, flake-utils }: { - overlays.default = final: prev: { - proserver-cli = final.callPackage - ({ stdenv, pkgs, ... }: - stdenv.mkDerivation { - src = ./.; - pname = "proserver-cli"; - version = "1.0.1"; - } - ) - { }; - }; - } // + outputs = { self, nixpkgs, flake-utils }: { } // (flake-utils.lib.eachDefaultSystem (system: let pkgs = import nixpkgs { system = system; - overlays = [ self.overlays.default ]; }; lib = nixpkgs.lib; in From f80f4e839f38631a1e32e237c8b689c8209a0246 Mon Sep 17 00:00:00 2001 From: Pilz <48645439+pilz0@users.noreply.github.com> Date: Thu, 26 Feb 2026 10:49:07 +0100 Subject: [PATCH 5/5] Update flake.nix Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --- flake.nix | 1 - 1 file changed, 1 deletion(-) diff --git a/flake.nix b/flake.nix index 4e30a45..df4214a 100644 --- a/flake.nix +++ b/flake.nix @@ -10,7 +10,6 @@ pkgs = import nixpkgs { system = system; }; - lib = nixpkgs.lib; in { packages = {