2021-01-25 08:26:54 +00:00
|
|
|
{ lib, fetchFromGitHub, fetchpatch, rustPlatform
|
2021-01-19 06:50:56 +00:00
|
|
|
, openssl, cmake, perl, pkg-config, zlib, curl, libgit2, libssh2
|
2019-11-23 02:14:30 +00:00
|
|
|
}:
|
2017-05-09 12:04:43 +01:00
|
|
|
|
|
|
|
with rustPlatform;
|
|
|
|
|
|
|
|
buildRustPackage rec {
|
|
|
|
version = "0.9.1";
|
2019-08-31 12:41:23 +01:00
|
|
|
pname = "git-series";
|
2017-05-09 12:04:43 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "git-series";
|
|
|
|
repo = "git-series";
|
|
|
|
rev = version;
|
|
|
|
sha256 = "07mgq5h6r1gf3jflbv2khcz32bdazw7z1s8xcsafdarnm13ps014";
|
|
|
|
};
|
|
|
|
|
2020-03-09 01:15:32 +00:00
|
|
|
cargoSha256 = "0ijgx8fksg2najb336dhddxlqfzc338f9ylydkpw6b39k72mm00d";
|
2017-08-05 15:38:48 +01:00
|
|
|
|
2019-10-16 18:19:32 +01:00
|
|
|
cargoPatches = [
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/Mic92/git-series/commit/3aa30a47d74ebf90b444dccdf8c153f07f119483.patch";
|
|
|
|
sha256 = "06v8br9skvy75kcw2zgbswxyk82sqzc8smkbqpzmivxlc2i9rnh0";
|
|
|
|
})
|
2019-10-16 18:39:17 +01:00
|
|
|
# Update Cargo.lock to allow using OpenSSL 1.1
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/edef1c/git-series/commit/11fe70ffcc18200e5f2a159c36aab070e8ff4228.patch";
|
|
|
|
sha256 = "0clwllf9mrhq86dhzyyhkw1q2ggpgqpw7s05dvp3gj9zhfsyya4s";
|
|
|
|
})
|
2020-01-06 21:40:42 +00:00
|
|
|
# Cargo.lock: Update url, which fixes incompatibility with NLL
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/edef1c/git-series/commit/27ff2ecf2d615dae1113709eca0e43596de12ac4.patch";
|
|
|
|
sha256 = "1byjbdcx56nd0bbwz078bl340rk334mb34cvaa58h76byvhpkw10";
|
|
|
|
})
|
2019-10-16 18:19:32 +01:00
|
|
|
];
|
2017-05-09 12:04:43 +01:00
|
|
|
|
2019-10-17 08:08:32 +01:00
|
|
|
LIBGIT2_SYS_USE_PKG_CONFIG = true;
|
2019-11-23 02:16:18 +00:00
|
|
|
LIBSSH2_SYS_USE_PKG_CONFIG = true;
|
2021-01-19 06:50:56 +00:00
|
|
|
nativeBuildInputs = [ cmake pkg-config perl ];
|
2019-11-23 02:16:18 +00:00
|
|
|
buildInputs = [ openssl zlib curl libgit2 libssh2 ];
|
2017-05-09 12:04:43 +01:00
|
|
|
|
2017-06-05 17:58:16 +01:00
|
|
|
postBuild = ''
|
2017-08-05 15:38:48 +01:00
|
|
|
install -D "$src/git-series.1" "$out/man/man1/git-series.1"
|
2017-06-05 17:58:16 +01:00
|
|
|
'';
|
|
|
|
|
2021-01-23 12:26:19 +00:00
|
|
|
meta = with lib; {
|
2017-05-09 12:04:43 +01:00
|
|
|
description = "A tool to help with formatting git patches for review on mailing lists";
|
|
|
|
longDescription = ''
|
|
|
|
git series tracks changes to a patch series over time. git
|
|
|
|
series also tracks a cover letter for the patch series,
|
|
|
|
formats the series for email, and prepares pull requests.
|
|
|
|
'';
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://github.com/git-series/git-series";
|
2017-05-09 12:04:43 +01:00
|
|
|
|
|
|
|
license = licenses.mit;
|
2019-10-17 18:47:12 +01:00
|
|
|
maintainers = with maintainers; [ edef vmandela ];
|
2017-05-09 12:04:43 +01:00
|
|
|
};
|
|
|
|
}
|