diff --git a/doc/release-notes/rl-2511.section.md b/doc/release-notes/rl-2511.section.md index 6f83bb58d734..c6195a3017c1 100644 --- a/doc/release-notes/rl-2511.section.md +++ b/doc/release-notes/rl-2511.section.md @@ -195,6 +195,8 @@ - `rofi-emoji-wayland` has been merged into `rofi-emoji` as `rofi` has been updated to `2.0.0` and supports both X11 & Wayland. +- The main binary of `tomlq` has been renamed from `tomlq` to `tq`. + - `emacs-macport` has been moved to a fork of Mitsuharu Yamamoto's patched source code starting with Emacs v30 as the original project seems to be currently dormant. All older versions of this package have been dropped. This introduces some backwards‐incompatible changes; see the NEWS for details. NEWS can be viewed from Emacs by typing `C-h n`, or by clicking `Help->Emacs News` from the menu bar. diff --git a/pkgs/by-name/to/tomlq/package.nix b/pkgs/by-name/to/tomlq/package.nix index 12faeecefc4e..82596469c26d 100644 --- a/pkgs/by-name/to/tomlq/package.nix +++ b/pkgs/by-name/to/tomlq/package.nix @@ -2,25 +2,33 @@ lib, rustPlatform, fetchFromGitHub, + versionCheckHook, + nix-update-script, }: -rustPlatform.buildRustPackage rec { +rustPlatform.buildRustPackage (finalAttrs: { pname = "tomlq"; - version = "0.1.6"; + version = "0.2.2"; src = fetchFromGitHub { owner = "cryptaliagy"; repo = "tomlq"; - tag = version; - hash = "sha256-g8xjz8qCTiulTwcEbLTHYldw4PI+4ZfCOMJs+J6L1C4="; + tag = finalAttrs.version; + hash = "sha256-obOR9q+fE5BnqZIsoL4zauKB+djEn1epqGwSjrI7QqU="; }; - cargoHash = "sha256-/n1+8n0zGs9qS5QQcAfXJ1kmRkcfsCTxQonEaFsNdHo="; + cargoHash = "sha256-RkzAYVMycQwcewuP8wDbL06YddapyFhm+57CGOICey0="; + + nativeInstallCheckInputs = [ versionCheckHook ]; + doInstallCheck = true; + + passthru.updateScript = nix-update-script { }; meta = { description = "Tool for getting data from TOML files on the command line"; homepage = "https://github.com/cryptaliagy/tomlq"; + changelog = "https://github.com/cryptaliagy/tomlq/releases/tag/${finalAttrs.version}"; license = lib.licenses.mit; maintainers = with lib.maintainers; [ kinzoku ]; mainProgram = "tq"; }; -} +}) diff --git a/pkgs/development/python-modules/flaxlib/default.nix b/pkgs/development/python-modules/flaxlib/default.nix index 2848c216f956..b9bf868d13b1 100644 --- a/pkgs/development/python-modules/flaxlib/default.nix +++ b/pkgs/development/python-modules/flaxlib/default.nix @@ -26,7 +26,7 @@ buildPythonPackage rec { postPatch = '' expected_version="$version" - actual_version=$(${lib.getExe tomlq} --file pyproject.toml "project.version") + actual_version=$(${lib.getExe tomlq} --raw --file pyproject.toml "project.version") if [ "$actual_version" != "$expected_version" ]; then echo -e "\n\tERROR:"