fetchFromBitBucket: auto-remove an impure file
Also fix the hash in goPackages.inflect, the only user of the fetcher ATM. Closes #12002 (different `inflect` fix), fixes #12012. Using fetchzip-derived functions is likely more efficient than fetchhg, and it's lighter on dependencies (hash is the same as with fetchhg in this case).
This commit is contained in:
@@ -10,6 +10,7 @@
|
||||
{ # Optionally move the contents of the unpacked tree up one level.
|
||||
stripRoot ? true
|
||||
, url
|
||||
, extraPostFetch ? ""
|
||||
, ... } @ args:
|
||||
|
||||
lib.overrideDerivation (fetchurl ({
|
||||
@@ -47,7 +48,8 @@ lib.overrideDerivation (fetchurl ({
|
||||
fi
|
||||
'' else ''
|
||||
mv "$unpackDir"/* "$out/"
|
||||
'');
|
||||
} // removeAttrs args [ "stripRoot" ]))
|
||||
'') #*/
|
||||
+ extraPostFetch;
|
||||
} // removeAttrs args [ "stripRoot" "extraPostFetch" ]))
|
||||
# Hackety-hack: we actually need unzip hooks, too
|
||||
(x: {nativeBuildInputs = x.nativeBuildInputs++ [unzip];})
|
||||
|
||||
Reference in New Issue
Block a user