mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-02 11:53:27 +00:00
755b915a15
nix run nixpkgs#silver-searcher -- -G '\.nix$' -0l 'description.*"[Aa]n?' pkgs \ | xargs -0 nix run nixpkgs#gnused -- -i '' -Ee 's/(description.*")[Aa]n? (.)/\1\U\2/'
50 lines
1.1 KiB
Nix
50 lines
1.1 KiB
Nix
{ lib
|
|
, stdenvNoCC
|
|
, fetchFromGitHub
|
|
, curl
|
|
, installShellFiles
|
|
, makeWrapper
|
|
}:
|
|
|
|
stdenvNoCC.mkDerivation rec {
|
|
pname = "rfc";
|
|
version = "1.0.0";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "bfontaine";
|
|
repo = "rfc";
|
|
rev = "v${version}";
|
|
hash = "sha256-zN+MQtHh69PkzbrfceHFpBYCPmTg9qrOf/ML2efq6Xk=";
|
|
};
|
|
|
|
nativeBuildInputs = [ installShellFiles makeWrapper ];
|
|
|
|
dontConfigure = true;
|
|
dontBuild = true;
|
|
|
|
installPhase = ''
|
|
runHook preInstall
|
|
|
|
install -Dm755 -t $out/bin rfc
|
|
wrapProgram $out/bin/rfc \
|
|
--prefix PATH : ${lib.makeBinPath [ curl ]}
|
|
installManPage man/rfc.1
|
|
|
|
runHook postInstall
|
|
'';
|
|
|
|
meta = with lib; {
|
|
description = "Tool to read RFCs from the command line";
|
|
longDescription = ''
|
|
rfc is a little tool written in Bash to read RFCs from the command-line.
|
|
It fetches RFCs and drafts from the Web and caches them locally.
|
|
'';
|
|
homepage = "https://github.com/bfontaine/rfc";
|
|
changelog = "https://github.com/bfontaine/rfc/blob/${src.rev}/CHANGELOG.md";
|
|
license = licenses.mit;
|
|
maintainers = with maintainers; [ azahi ];
|
|
platforms = platforms.all;
|
|
mainProgram = "rfc";
|
|
};
|
|
}
|