diff options
author | Florian Klink <flokli@flokli.de> | 2022-01-19 19:05:28 +0100 |
---|---|---|
committer | Florian Klink <flokli@flokli.de> | 2022-01-19 19:13:36 +0100 |
commit | f37a71a73706590b45ad82e98042702c4abf4a93 (patch) | |
tree | 2558bf1c10db043dcd5b1eb2c77385149854750c /pkgs/development | |
parent | 4a94071fb3e4fddc8b98dc13104ac720eceb728c (diff) | |
download | nixpkgs-f37a71a73706590b45ad82e98042702c4abf4a93.tar nixpkgs-f37a71a73706590b45ad82e98042702c4abf4a93.tar.gz nixpkgs-f37a71a73706590b45ad82e98042702c4abf4a93.tar.bz2 nixpkgs-f37a71a73706590b45ad82e98042702c4abf4a93.tar.lz nixpkgs-f37a71a73706590b45ad82e98042702c4abf4a93.tar.xz nixpkgs-f37a71a73706590b45ad82e98042702c4abf4a93.tar.zst nixpkgs-f37a71a73706590b45ad82e98042702c4abf4a93.zip |
drush: 6.1.0 -> 8.4.10
Drush 6.x is unsupported, and not compatible with any PHP version we ship in nixpkgs. Drush 8.x still supports Drupal 6, 7 and 8. I switched to using the released .phar, instead of trying to nixify the composer dependencies.
Diffstat (limited to 'pkgs/development')
-rw-r--r-- | pkgs/development/tools/misc/drush/default.nix | 46 |
1 files changed, 18 insertions, 28 deletions
diff --git a/pkgs/development/tools/misc/drush/default.nix b/pkgs/development/tools/misc/drush/default.nix index e2be56b638e..8cafab36f2a 100644 --- a/pkgs/development/tools/misc/drush/default.nix +++ b/pkgs/development/tools/misc/drush/default.nix @@ -2,40 +2,30 @@ stdenv.mkDerivation rec { pname = "drush"; - version = "6.1.0"; + version = "8.4.10"; - meta = with lib; { - description = "Command-line shell and Unix scripting interface for Drupal"; - homepage = "https://github.com/drush-ops/drush"; - license = licenses.gpl2; - maintainers = with maintainers; [ lovek323 ]; - platforms = platforms.all; + src = fetchurl { + url = "https://github.com/drush-ops/drush/releases/download/${version}/drush.phar"; + sha256 = "sha256-yXSoTDFLsjDiYkRfrIxv2WTVdHzgxZRvtn3Pht5XF4k="; }; - src = fetchFromGitHub { - owner = "drush-ops"; - repo = pname; - rev = version; - sha256 = "sha256-0nf/m+xJmfHsFLuordiMp8UyrGGXuS70+zFHkIxLWhU="; - }; - - consoleTable = fetchurl { - url = "http://download.pear.php.net/package/Console_Table-1.1.3.tgz"; - sha256 = "07gbjd7m1fj5dmavr0z20vkqwx1cz2522sj9022p257jifj1yl76"; - }; + dontUnpack = true; nativeBuildInputs = [ makeWrapper ]; installPhase = '' - # install libraries - cd lib - tar -xf ${consoleTable} - cd .. - - mkdir -p "$out" - cp -r . "$out/src" - mkdir "$out/bin" - wrapProgram "$out/src/drush" --prefix PATH : "${lib.makeBinPath [ which php bash coreutils ncurses ]}" - ln -s "$out/src/drush" "$out/bin/drush" + mkdir -p $out/bin + install -D $src $out/libexec/drush/drush.phar + makeWrapper ${php}/bin/php $out/bin/drush \ + --add-flags "$out/libexec/drush/drush.phar" \ + --prefix PATH : "${lib.makeBinPath [ which php bash coreutils ncurses ]}" ''; + + meta = with lib; { + description = "Command-line shell and Unix scripting interface for Drupal"; + homepage = "https://github.com/drush-ops/drush"; + license = licenses.gpl2; + maintainers = with maintainers; [ lovek323 ]; + platforms = platforms.all; + }; } |