diff options
author | github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> | 2023-09-12 18:01:30 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-09-12 18:01:30 +0000 |
commit | 564dc31f47ac641bdd42f3d0998fc411c05d56fa (patch) | |
tree | 5a0c7067ae569ccb16976732066a5f632f22c3b8 /pkgs/by-name/qu/quicktype/package.nix | |
parent | 757197a9dfbe52b16b116b39ada02d4e4098b4af (diff) | |
parent | 41b9c0a6d9467cece015ffc7016b9e7e73542157 (diff) | |
download | nixpkgs-564dc31f47ac641bdd42f3d0998fc411c05d56fa.tar nixpkgs-564dc31f47ac641bdd42f3d0998fc411c05d56fa.tar.gz nixpkgs-564dc31f47ac641bdd42f3d0998fc411c05d56fa.tar.bz2 nixpkgs-564dc31f47ac641bdd42f3d0998fc411c05d56fa.tar.lz nixpkgs-564dc31f47ac641bdd42f3d0998fc411c05d56fa.tar.xz nixpkgs-564dc31f47ac641bdd42f3d0998fc411c05d56fa.tar.zst nixpkgs-564dc31f47ac641bdd42f3d0998fc411c05d56fa.zip |
Merge staging-next into staging
Diffstat (limited to 'pkgs/by-name/qu/quicktype/package.nix')
-rw-r--r-- | pkgs/by-name/qu/quicktype/package.nix | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/pkgs/by-name/qu/quicktype/package.nix b/pkgs/by-name/qu/quicktype/package.nix new file mode 100644 index 00000000000..20ce7b39fb3 --- /dev/null +++ b/pkgs/by-name/qu/quicktype/package.nix @@ -0,0 +1,31 @@ +{ lib, buildNpmPackage, fetchFromGitHub, jq }: + +buildNpmPackage rec { + pname = "quicktype"; + version = "23.0.75"; # version from https://npm.im/quicktype + + src = fetchFromGitHub { + owner = "quicktype"; + repo = "quicktype"; + rev = "9b570a73a896306778940c793c0037a38815304a"; # version not tagged + hash = "sha256-boCBgIoM2GECipZTJlp9IaeXT24aR8tawS1X8CFDDqw="; + }; + + postPatch = '' + cat <<< $(${jq}/bin/jq '.version = "${version}"' package.json) > package.json + ''; + + npmDepsHash = "sha256-RA4HVQfB/ge1aIKl9HiUT7vUM5n+Ro6N2D6xj1dgSu8="; + + postInstall = '' + mv packages/ $out/lib/node_modules/quicktype/ + ''; + + meta = with lib; { + description = "Generate types and converters from JSON, Schema, and GraphQL"; + homepage = "https://quicktype.io/"; + license = licenses.asl20; + maintainers = [ maintainers.marsam ]; + mainProgram = "quicktype"; + }; +} |