From d99e4119792b832928a0306d0f342710b53a6ef3 Mon Sep 17 00:00:00 2001 From: Benedikt Peetz Date: Mon, 30 Dec 2024 18:53:10 +0100 Subject: feat(scripts/deployed): Track successful deployments --- deployes/zsa_moonlander_0.27.1-dirty-26 | Bin 0 -> 50968 bytes package.nix | 5 ++--- scripts/deployed.sh | 9 +++++++++ version.nix | 2 ++ 4 files changed, 13 insertions(+), 3 deletions(-) create mode 100755 deployes/zsa_moonlander_0.27.1-dirty-26 create mode 100755 scripts/deployed.sh create mode 100644 version.nix diff --git a/deployes/zsa_moonlander_0.27.1-dirty-26 b/deployes/zsa_moonlander_0.27.1-dirty-26 new file mode 100755 index 0000000..4766a10 Binary files /dev/null and b/deployes/zsa_moonlander_0.27.1-dirty-26 differ diff --git a/package.nix b/package.nix index 7db364e..5a239c8 100644 --- a/package.nix +++ b/package.nix @@ -29,8 +29,7 @@ requirements.txt ''; - # NOTE: Change this _EVERY_ time you actually use a new keymap. <2024-12-29> - version = "26"; + version = import ./version.nix; in stdenv.mkDerivation { @@ -138,7 +137,7 @@ in fd . $out/build --type empty --type directory --hidden --exec rm --dir done - ln --symbolic --relative "$out/build/zsa_moonlander_${layout_id}.bin" "$out/binary_output/" + ln --symbolic --relative "$out/build/zsa_moonlander_${layout_id}.bin" "$out/binary_output/zsa_moonlander_$QMK_VERSION" runHook postInstall ''; diff --git a/scripts/deployed.sh b/scripts/deployed.sh new file mode 100755 index 0000000..c92693b --- /dev/null +++ b/scripts/deployed.sh @@ -0,0 +1,9 @@ +#!/usr/bin/env sh + +version="$(nix eval --file ./version.nix)" + +echo "\"$((version + 1))\"" >./version.nix + +cp ./result/binary_output/zsa_moonlander_* deployes/ + +# vim: ft=sh diff --git a/version.nix b/version.nix new file mode 100644 index 0000000..e60a901 --- /dev/null +++ b/version.nix @@ -0,0 +1,2 @@ +# NOTE: Change this _EVERY_ time you actually use a new keymap. <2024-12-29> +"26" -- cgit 1.4.1