Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
argotk
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
argo
argotk
Commits
1dbf6426
Commit
1dbf6426
authored
Feb 20, 2019
by
Valentin Reis
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Style.
parent
e34cc0dd
Pipeline
#5471
passed with stage
in 36 seconds
Changes
2
Pipelines
1
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
264 additions
and
281 deletions
+264
-281
src/Argo/Stack.hs
src/Argo/Stack.hs
+13
-17
src/argotk.hs
src/argotk.hs
+251
-264
No files found.
src/Argo/Stack.hs
View file @
1dbf6426
{-#
LANGUAGE
TupleSections,
LambdaCase,
RecordWildCards,
OverloadedStrings #-}
{-#
language TupleSections #-}
{-# language ViewPatterns #-}
{-# language LambdaCase #-}
{-# language RecordWildCards #-}
{-# language
OverloadedStrings #-}
{-|
Module : Argo.Stack
...
...
@@ -177,12 +177,11 @@ instance Show StackI where
Performance
->
"cmd listen -f performance"
runStack
::
StackArgs
->
Shell
StackOutput
runStack
sa
@
StackArgs
{
..
}
=
do
when
(
verbosity
==
Verbose
)
$
liftIO
$
pPrint
sa
runStack
sa
@
StackArgs
{
verbosity
=
(
==
Verbose
)
->
verbose
,
..
}
=
do
when
verbose
$
liftIO
$
pPrint
sa
cleanLeftovers
workingDirectory
CM
.
mapM_
(
$
(
coerce
workingDirectory
::
FilePath
))
[
mktree
,
cd
]
CM
.
mapM_
(
$
(
coerce
workingDirectory
))
[
mktree
,
cd
]
iDaemon
<-
case
daemon
of
DontRun
->
return
Nothing
...
...
@@ -202,21 +201,19 @@ runStack sa@StackArgs {..} = do
ilist
=
catMaybes
milist
_
<-
shell
(
coerce
preludeCommand
::
Text
)
empty
>>=
\
case
ExitSuccess
->
when
(
verbosity
==
Verbose
)
ExitSuccess
->
when
verbose
$
printInfo
(
"Executed preludeCommand."
<>
repr
preludeCommand
)
ExitFailure
_
->
die
(
"failed to execute preludeCommand."
<>
repr
preludeCommand
)
if
verbosity
==
Verbose
then
do
printInfo
"Starting the following processes:"
liftIO
$
pPrint
ilist
else
liftIO
$
pPrint
(
fmap
fst
ilist
)
when
verbose
$
do
printInfo
"Starting the following processes:"
liftIO
$
pPrint
ilist
asyncs
<-
liftIO
$
mapM
tupleToAsync
ilist
_
<-
liftIO
$
kbInstallHandler
$
CM
.
mapM_
cancel
asyncs
when
(
verbosity
==
Verbose
)
$
printInfo
"Processes started."
when
verbose
$
printInfo
"Processes started."
out
<-
liftIO
$
waitAnyCancel
asyncs
...
...
@@ -241,7 +238,6 @@ runStack sa@StackArgs {..} = do
tracebackList
cd
"../"
return
r
where
procsWithTracebacks
...
...
src/argotk.hs
View file @
1dbf6426
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a 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