nur-packages

My NUR packages
git clone git://git.sikmir.ru/nur-packages
Log | Files | Refs | README | LICENSE

package.nix (1311B)


      1 {
      2   stdenv,
      3   lib,
      4   fetchFromGitHub,
      5   python3Packages,
      6   installShellFiles,
      7   writableTmpDirAsHomeHook,
      8 }:
      9 
     10 python3Packages.buildPythonApplication (finalAttrs: {
     11   pname = "yt-cli";
     12   version = "0.25.1";
     13   pyproject = true;
     14 
     15   __structuredAttrs = true;
     16 
     17   src = fetchFromGitHub {
     18     owner = "ryancheley";
     19     repo = "yt-cli";
     20     tag = "v${finalAttrs.version}";
     21     hash = "sha256-niOyM9VQ+xHddOiI0U60m5zDYlZV3eMtvnbLC+acWvg=";
     22   };
     23 
     24   build-system = with python3Packages; [ hatchling ];
     25 
     26   dependencies = with python3Packages; [
     27     rich
     28     textual
     29     pydantic
     30     click
     31     httpx
     32     python-dotenv
     33     pydantic-settings
     34     structlog
     35     keyring
     36     cryptography
     37     ty
     38     docker
     39   ];
     40 
     41   nativeBuildInputs = [
     42     installShellFiles
     43     writableTmpDirAsHomeHook
     44   ];
     45 
     46   postInstall = lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
     47     installShellCompletion --cmd yt \
     48       --bash <($out/bin/yt completion bash) \
     49       --fish <($out/bin/yt completion fish) \
     50       --zsh <($out/bin/yt completion zsh)
     51   '';
     52 
     53   meta = {
     54     description = "Command line interface for JetBrains YouTrack issue tracking system";
     55     homepage = "https://github.com/ryancheley/yt-cli";
     56     license = lib.licenses.mit;
     57     maintainers = [ lib.maintainers.sikmir ];
     58     mainProgram = "yt";
     59   };
     60 })