mirror of
https://github.com/nmattia/niv.git
synced 2024-11-07 22:36:53 +03:00
Consider .tgz as .tar.gz
This commit is contained in:
parent
372f96bff2
commit
5b5508f855
@ -33,7 +33,7 @@ githubUpdate prefetch latestRev ghRepo = proc () -> do
|
||||
(useOrSet "url_template" <<< completeSpec) <+> (load "url_template") -<
|
||||
()
|
||||
url <- update "url" -< urlTemplate
|
||||
let isTar = ("tar.gz" `T.isSuffixOf`) <$> url
|
||||
let isTar = (\u -> "tar.gz" `T.isSuffixOf` u || ".tgz" `T.isSuffixOf` u) <$> url
|
||||
useOrSet "type" -< bool "file" "tarball" <$> isTar :: Box T.Text
|
||||
let doUnpack = isTar
|
||||
_sha256 <- update "sha256" <<< run (\(up, u) -> prefetch up u) -< (,) <$> doUnpack <*> url
|
||||
|
Loading…
Reference in New Issue
Block a user