2021-10-22 15:51:22 +01:00
|
|
|
{ lib
|
|
|
|
, rustPlatform
|
|
|
|
, fetchFromGitHub
|
|
|
|
, cmake
|
|
|
|
, pkg-config
|
|
|
|
, stdenv
|
|
|
|
, libiconv
|
|
|
|
, Security
|
|
|
|
, SystemConfiguration
|
|
|
|
, openssl
|
|
|
|
}:
|
2020-08-16 07:26:59 +01:00
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "gitoxide";
|
2021-10-22 15:51:22 +01:00
|
|
|
version = "0.10.0";
|
2020-08-16 07:26:59 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "Byron";
|
|
|
|
repo = "gitoxide";
|
|
|
|
rev = "v${version}";
|
2021-10-22 15:51:22 +01:00
|
|
|
sha256 = "sha256-c29gmmkIOyS+HNq2kv53yq+sdEDmQbSmcvVGcd55/hk=";
|
2020-08-16 07:26:59 +01:00
|
|
|
};
|
|
|
|
|
2021-10-22 15:51:22 +01:00
|
|
|
cargoSha256 = "sha256-oc7XpiOZj4bfqdwrEHj/CzNtWzYWFkgMJOySJNgxAGQ=";
|
2020-09-13 20:08:17 +01:00
|
|
|
|
2021-05-10 03:40:00 +01:00
|
|
|
nativeBuildInputs = [ cmake pkg-config ];
|
2021-05-15 20:42:38 +01:00
|
|
|
buildInputs = if stdenv.isDarwin
|
2021-10-22 15:51:22 +01:00
|
|
|
then [ libiconv Security SystemConfiguration ]
|
2021-05-15 20:42:38 +01:00
|
|
|
else [ openssl ];
|
2020-09-13 20:08:17 +01:00
|
|
|
|
2021-01-19 06:50:56 +00:00
|
|
|
# Needed to get openssl-sys to use pkg-config.
|
2020-09-13 20:08:17 +01:00
|
|
|
OPENSSL_NO_VENDOR = 1;
|
2020-08-16 07:26:59 +01:00
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2020-12-30 02:05:47 +00:00
|
|
|
description = "A command-line application for interacting with git repositories";
|
2020-08-16 07:26:59 +01:00
|
|
|
homepage = "https://github.com/Byron/gitoxide";
|
2021-10-22 15:51:22 +01:00
|
|
|
changelog = "https://github.com/Byron/gitoxide/blob/v${version}/CHANGELOG.md";
|
2020-09-13 20:08:17 +01:00
|
|
|
license = with licenses; [ mit /* or */ asl20 ];
|
2021-10-22 15:51:22 +01:00
|
|
|
maintainers = with maintainers; [ syberant ];
|
2020-08-16 07:26:59 +01:00
|
|
|
};
|
|
|
|
}
|