2019-12-20 12:09:28 +02:00
|
|
|
{ stdenv, fetchFromGitHub, rustPlatform
|
|
|
|
, libiconv, Security }:
|
2019-08-16 13:12:52 -04:00
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "starship";
|
2020-01-06 13:27:44 -05:00
|
|
|
version = "0.33.0";
|
2019-08-16 13:12:52 -04:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "starship";
|
2019-12-03 19:10:30 +02:00
|
|
|
repo = pname;
|
2019-08-16 13:12:52 -04:00
|
|
|
rev = "v${version}";
|
2020-01-06 13:27:44 -05:00
|
|
|
sha256 = "1wqxcfd7ams3k0swps9037dzc1qzxhpbqaz4qjw9jabgcl6jkb6v";
|
2019-08-16 13:12:52 -04:00
|
|
|
};
|
|
|
|
|
2019-12-22 18:07:58 +02:00
|
|
|
buildInputs = stdenv.lib.optionals stdenv.isDarwin [ libiconv Security ];
|
2019-08-16 13:12:52 -04:00
|
|
|
|
2019-12-03 19:37:29 +02:00
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace src/utils.rs \
|
|
|
|
--replace "/bin/echo" "echo"
|
|
|
|
'';
|
|
|
|
|
2020-01-06 13:27:44 -05:00
|
|
|
cargoSha256 = "0gcca3vlwrfhw9k4r9zc1raflr1m4xws9dpdxjh1kz34f9g88ijg";
|
2019-08-19 12:17:24 -04:00
|
|
|
checkPhase = "cargo test -- --skip directory::home_directory --skip directory::directory_in_root";
|
2019-08-16 13:12:52 -04:00
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "A minimal, blazing fast, and extremely customizable prompt for any shell";
|
|
|
|
homepage = "https://starship.rs";
|
|
|
|
license = licenses.isc;
|
2019-12-03 19:10:55 +02:00
|
|
|
maintainers = with maintainers; [ bbigras davidtwco filalex77 ];
|
2019-08-16 13:12:52 -04:00
|
|
|
platforms = platforms.all;
|
|
|
|
};
|
|
|
|
}
|