Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ 2 lib, 3 fetchFromGitLab, 4 php, 5 nixosTests, 6 writeScript, 7}: 8 9php.buildComposerProject2 (finalAttrs: { 10 pname = "drupal"; 11 version = "11.2.1"; 12 13 src = fetchFromGitLab { 14 domain = "git.drupalcode.org"; 15 owner = "project"; 16 repo = "drupal"; 17 tag = finalAttrs.version; 18 hash = "sha256-GlQvgI3dmRSHtNky0ZL4Y4VWIaUrO+EjPwnkkF9DJDQ="; 19 }; 20 21 vendorHash = "sha256-2XqYxuIlnXzyvOYtY67H1hOuuFjApi0H5VV74j/RJzI="; 22 composerNoPlugins = false; 23 24 passthru = { 25 tests = { 26 inherit (nixosTests) drupal; 27 }; 28 updateScript = writeScript "update.sh" '' 29 #!/usr/bin/env nix-shell 30 #!nix-shell -i bash -p common-updater-scripts xmlstarlet 31 set -eu -o pipefail 32 version=$(curl -k --silent --globoff "https://updates.drupal.org/release-history/drupal/current" | xmlstarlet sel -t -v "project/releases/release[1]/tag") 33 update-source-version drupal $version --file=./pkgs/by-name/dr/drupal/package.nix 34 ''; 35 }; 36 37 meta = { 38 description = "Drupal CMS"; 39 license = lib.licenses.mit; 40 homepage = "https://drupal.org/"; 41 maintainers = with lib.maintainers; [ 42 drupol 43 OulipianSummer 44 ]; 45 platforms = php.meta.platforms; 46 }; 47})