2023-08-10 07:59:29 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, fetchFromGitHub
|
|
|
|
, testers
|
|
|
|
, zig_0_11
|
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation (finalAttrs: {
|
|
|
|
pname = "dt";
|
2023-11-16 04:20:00 +00:00
|
|
|
version = "1.3.1";
|
2023-08-10 07:59:29 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "so-dang-cool";
|
|
|
|
repo = "dt";
|
|
|
|
rev = "v${finalAttrs.version}";
|
2023-11-16 04:20:00 +00:00
|
|
|
hash = "sha256-qHfvHf4T0wWnzqp5FfLg7n7te24xc2aMEdTK3Iia8Q0=";
|
2023-08-10 07:59:29 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [ zig_0_11.hook ];
|
|
|
|
|
2023-08-22 20:05:09 +00:00
|
|
|
passthru.tests.version = testers.testVersion { package = finalAttrs.finalPackage; };
|
2023-08-10 07:59:29 +00:00
|
|
|
|
|
|
|
meta = {
|
|
|
|
homepage = "https://dt.plumbing";
|
2023-08-22 20:05:09 +00:00
|
|
|
description = "Duct tape for your unix pipes";
|
2023-08-10 07:59:29 +00:00
|
|
|
longDescription = ''
|
2023-08-22 20:05:09 +00:00
|
|
|
dt is a utility and programming language. The utility is intended for
|
|
|
|
ergonomic in-the-shell execution. The language is straightforward (in
|
|
|
|
the most literal sense) with a minimal syntax that allows for
|
|
|
|
high-level, higher-order programming.
|
2023-08-10 07:59:29 +00:00
|
|
|
|
2023-08-22 20:05:09 +00:00
|
|
|
It's meant to supplement (not replace!) other tools like awk, sed,
|
|
|
|
xargs, and shell built-ins. Something like the Perl one-liners popular
|
|
|
|
yesteryear, but hopefully easier to read and reason through.
|
2023-08-10 07:59:29 +00:00
|
|
|
|
2023-08-22 20:05:09 +00:00
|
|
|
In short, dt is intended to be generally useful, with zero pretense of
|
|
|
|
elegance.
|
2023-08-10 07:59:29 +00:00
|
|
|
'';
|
2023-10-09 19:29:22 +00:00
|
|
|
changelog = "https://github.com/so-dang-cool/dt/releases/tag/v${finalAttrs.version}";
|
2023-08-10 07:59:29 +00:00
|
|
|
license = lib.licenses.bsd3;
|
|
|
|
maintainers = with lib.maintainers; [ booniepepper ];
|
2023-10-09 19:29:22 +00:00
|
|
|
platforms = lib.platforms.unix;
|
2023-08-10 07:59:29 +00:00
|
|
|
mainProgram = "dt";
|
|
|
|
};
|
|
|
|
})
|