anchor.diff:  
     passthru = {
       updateScript = nix-update-script {
  -      attrPath = pname;
  +      attrPath = self.pname;
       };
     };
   
     meta = with lib; {
       description = "A package manager for Lua";
  -    license = licenses.mit ;
  -    maintainers = with maintainers; [raskin teto];
  +    license = licenses.mit;
  +    maintainers = with maintainers; [ raskin teto ];
       platforms = platforms.linux ++ platforms.darwin;
       downloadPage = "http://luarocks.org/releases/";
     };
  -}
  +})
  
positive.code: {lib, stdenv, fetchFromGitHub, buildPackages
  , fetchpatch
  , curl, makeWrapper, which, unzip
  , lua
  # for 'luarocks pack'
  , zip
  , nix-update-script
  # some packages need to be compiled with cmake
  , cmake
  , installShellFiles
  }:
  
  stdenv.mkDerivation rec {
    pname = "luarocks";
    version = "3.9.1";
  
    src = fetchFromGitHub {
      owner = "luarocks";
      repo = "luarocks";
      rev = "v${version}";
      sha256 = "sha256-G6HDap3pspeQtGDBq+ukN7kftDaT/CozMVdYM60F6HI=";
    };
  
  
negative.code:               --suffix LUA_PATH ";" "$(echo "$out"/share/lua/*/)?.lua" \
                --suffix LUA_PATH ";" "$(echo "$out"/share/lua/*/)?/init.lua" \
                --suffix LUA_CPATH ";" "$(echo "$out"/lib/lua/*/)?.so" \
                --suffix LUA_CPATH ";" "$(echo "$out"/share/lua/*/)?/init.lua" \
                --suffix PATH : ${lib.makeBinPath ([ unzip ] ++
                  lib.optionals (self.pname == "luarocks-nix") [ file nix-prefetch-git ])}
          }
      done
    '' + lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
      installShellCompletion --cmd luarocks \
        --bash <($out/bin/luarocks completion bash) \
        --fish <($out/bin/luarocks completion fish) \
        --zsh <($out/bin/luarocks completion zsh)
    '';
  
    propagatedBuildInputs = [ zip unzip cmake ];
  