From 453c8f415789e59f94902f326dc081a3271323ec Mon Sep 17 00:00:00 2001 From: Christoph Heiss Date: Thu, 6 Apr 2023 16:29:30 +0200 Subject: [PATCH] trurl: init at 0.3 This is a new tool for "translating and transposing URLs, made by curl's Daniel Sternberg. Signed-off-by: Christoph Heiss --- .../manual/release-notes/rl-2305.section.md | 2 ++ pkgs/tools/networking/trurl/default.nix | 33 +++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ 3 files changed, 37 insertions(+) create mode 100644 pkgs/tools/networking/trurl/default.nix diff --git a/nixos/doc/manual/release-notes/rl-2305.section.md b/nixos/doc/manual/release-notes/rl-2305.section.md index 46f324c3c0f6..42df4c9b6ed0 100644 --- a/nixos/doc/manual/release-notes/rl-2305.section.md +++ b/nixos/doc/manual/release-notes/rl-2305.section.md @@ -87,6 +87,8 @@ In addition to numerous new and upgraded packages, this release has the followin - [nimdow](https://github.com/avahe-kellenberger/nimdow), a window manager written in Nim, inspired by dwm. +- [trurl](https://github.com/curl/trurl), a command line tool for URL parsing and manipulation. + - [woodpecker-agents](https://woodpecker-ci.org/), a simple CI engine with great extensibility. Available as [services.woodpecker-agents](#opt-services.woodpecker-agents.agents._name_.enable). - [woodpecker-server](https://woodpecker-ci.org/), a simple CI engine with great extensibility. Available as [services.woodpecker-server](#opt-services.woodpecker-server.enable). diff --git a/pkgs/tools/networking/trurl/default.nix b/pkgs/tools/networking/trurl/default.nix new file mode 100644 index 000000000000..72343d6c3c2d --- /dev/null +++ b/pkgs/tools/networking/trurl/default.nix @@ -0,0 +1,33 @@ +{ lib, stdenv, fetchFromGitHub, curl, perl }: + +stdenv.mkDerivation rec { + pname = "trurl"; + version = "0.3"; + + src = fetchFromGitHub { + owner = "curl"; + repo = pname; + rev = "${pname}-${version}"; + sha256 = "sha256-z7Na7lXDzSmBTuSBaizyG892D3IfbN43ytPjOEQ9CAA="; + }; + + separateDebugInfo = stdenv.isLinux; + + enableParallelBuilding = true; + + buildInputs = [ curl ]; + makeFlags = [ "PREFIX=$(out)" ]; + + doCheck = true; + checkInputs = [ perl ]; + checkTarget = "test"; + + meta = with lib; { + description = "A command line tool for URL parsing and manipulation"; + homepage = "https://curl.se/trurl"; + changelog = "https://github.com/curl/trurl/releases/tag/${pname}-${version}"; + license = licenses.curl; + maintainers = with maintainers; [ christoph-heiss ]; + platforms = platforms.all; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index bbc9d709ada4..5104ba6080dc 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -6551,6 +6551,8 @@ with pkgs; curlie = callPackage ../tools/networking/curlie { }; + trurl = callPackage ../tools/networking/trurl { }; + cunit = callPackage ../tools/misc/cunit { }; bcunit = callPackage ../tools/misc/bcunit { };