mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-02-02 02:03:21 +00:00
Merge pull request #194895 from aaronjheng/trunk-io
This commit is contained in:
commit
759181d23f
28
pkgs/development/tools/trunk-io/default.nix
Normal file
28
pkgs/development/tools/trunk-io/default.nix
Normal file
@ -0,0 +1,28 @@
|
||||
{ lib, stdenv, fetchurl }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "trunk-io";
|
||||
version = "1.2.2";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://trunk.io/releases/launcher/${version}/trunk";
|
||||
sha256 = "sha256-+A9FUqcxF/zji2QGD50avYSAib4sq8u6R50YzRailMc=";
|
||||
};
|
||||
|
||||
dontUnpack = true;
|
||||
dontConfigure = true;
|
||||
dontBuild = true;
|
||||
|
||||
installPhase = ''
|
||||
install -D $src $out/bin/trunk
|
||||
'';
|
||||
|
||||
passthru.updateScript = ./update.sh;
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://trunk.io/";
|
||||
description = "Developer experience toolkit used to check, test, merge, and monitor code";
|
||||
license = licenses.unfree;
|
||||
maintainers = with maintainers; [ aaronjheng ];
|
||||
};
|
||||
}
|
7
pkgs/development/tools/trunk-io/update.sh
Executable file
7
pkgs/development/tools/trunk-io/update.sh
Executable file
@ -0,0 +1,7 @@
|
||||
#!/usr/bin/env nix-shell
|
||||
#!nix-shell -i bash -p curl pcre common-updater-scripts
|
||||
|
||||
set -eu -o pipefail
|
||||
|
||||
version="$(curl -fsSL https://trunk.io/releases/trunk | grep -Fi 'readonly TRUNK_LAUNCHER_VERSION=' | pcregrep -o1 '"(\d+(?:\.\d+)+)"')"
|
||||
update-source-version trunk-io "$version"
|
@ -12069,6 +12069,8 @@ with pkgs;
|
||||
inherit (darwin.apple_sdk.frameworks) CoreServices Security;
|
||||
};
|
||||
|
||||
trunk-io = callPackage ../development/tools/trunk-io { };
|
||||
|
||||
tthsum = callPackage ../applications/misc/tthsum { };
|
||||
|
||||
ttp = with python3.pkgs; toPythonApplication ttp;
|
||||
|
Loading…
Reference in New Issue
Block a user