Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
curry-packages
cpm
Commits
75e2749b
Commit
75e2749b
authored
Nov 04, 2020
by
Michael Hanus
Browse files
Add test for existence of CurryCheck in upload command
parent
ea85afe4
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/CPM/Main.curry
View file @
75e2749b
...
...
@@ -60,11 +60,11 @@ import CPM.ConfigPackage ( packagePath )
-- Banner of this tool:
cpmBanner :: String
cpmBanner = unlines [bannerLine,bannerText,bannerLine]
cpmBanner = unlines [bannerLine,
bannerText,
bannerLine]
where
bannerText =
"Curry Package Manager <curry-lang.org/tools/cpm> (version of
2
0/1
0
/2020)"
bannerLine = take (length bannerText) (repeat '-')
bannerText =
"Curry Package Manager <curry-lang.org/tools/cpm> (version of 0
4
/1
1
/2020)"
bannerLine = take (length bannerText) (repeat '-')
main :: IO ()
main = do
...
...
@@ -1685,7 +1685,9 @@ uploadCmd opts cfg = do
installPkg lpkg instdir
let pkgid = packageId lpkg
pkg <- loadPackageSpecELM (instdir </> pkgid)
ecode <- testPackage pkgid instdir
-- Test package if CurryCheck is installed:
mbccfile <- execIO $ getFileInPath "curry-check"
ecode <- maybe (return 0) (\_ -> testPackage pkgid instdir) mbccfile
if ecode > 0
then do execIO cleanTempDir
logMsg Critical "ERROR in package, package not uploaded!"
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment