2021-10-28 06:52:43 +00:00
|
|
|
{ lib
|
|
|
|
, rustPlatform
|
|
|
|
, fetchFromGitHub
|
|
|
|
, cmake
|
|
|
|
, pkg-config
|
|
|
|
, stdenv
|
|
|
|
, libiconv
|
|
|
|
, Security
|
|
|
|
, SystemConfiguration
|
2023-02-09 11:40:11 +00:00
|
|
|
, curl
|
2021-10-28 06:52:43 +00:00
|
|
|
, openssl
|
|
|
|
}:
|
2020-08-20 17:08:02 +00:00
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "gitoxide";
|
2023-02-22 10:55:15 +00:00
|
|
|
version = "0.22.1";
|
2020-08-20 17:08:02 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "Byron";
|
|
|
|
repo = "gitoxide";
|
|
|
|
rev = "v${version}";
|
2023-02-22 10:55:15 +00:00
|
|
|
sha256 = "sha256-PetU/cUWFZWl1OoSObI7wwqJLexWPTP6ynNSyPXjvMc=";
|
2020-08-20 17:08:02 +00:00
|
|
|
};
|
|
|
|
|
2023-02-22 10:55:15 +00:00
|
|
|
cargoHash = "sha256-A7gwC9EQ+5GVciGsL9uPbZ6nThPfku3ZNH8qQwfI0QQ=";
|
2020-09-25 04:45:31 +00:00
|
|
|
|
2021-05-20 23:08:51 +00:00
|
|
|
nativeBuildInputs = [ cmake pkg-config ];
|
2023-02-09 11:40:11 +00:00
|
|
|
buildInputs = [ curl ] ++ (if stdenv.isDarwin
|
2021-10-28 06:52:43 +00:00
|
|
|
then [ libiconv Security SystemConfiguration ]
|
2023-02-09 11:40:11 +00:00
|
|
|
else [ openssl ]);
|
2020-09-25 04:45:31 +00:00
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
# Needed to get openssl-sys to use pkg-config.
|
2020-09-25 04:45:31 +00:00
|
|
|
OPENSSL_NO_VENDOR = 1;
|
2020-08-20 17:08:02 +00:00
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2021-01-05 17:05:55 +00:00
|
|
|
description = "A command-line application for interacting with git repositories";
|
2020-08-20 17:08:02 +00:00
|
|
|
homepage = "https://github.com/Byron/gitoxide";
|
2021-10-28 06:52:43 +00:00
|
|
|
changelog = "https://github.com/Byron/gitoxide/blob/v${version}/CHANGELOG.md";
|
2020-09-25 04:45:31 +00:00
|
|
|
license = with licenses; [ mit /* or */ asl20 ];
|
2021-10-28 06:52:43 +00:00
|
|
|
maintainers = with maintainers; [ syberant ];
|
2020-08-20 17:08:02 +00:00
|
|
|
};
|
|
|
|
}
|