Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
clean-ide
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
6
Issues
6
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
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
clean-and-itasks
clean-ide
Commits
4f22fc33
Commit
4f22fc33
authored
Mar 06, 2013
by
Jurrien Stutterheim
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix remove path parsing and display success messages
parent
3ffd1bf8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
cpm/Cpm.icl
cpm/Cpm.icl
+3
-3
No files found.
cpm/Cpm.icl
View file @
4f22fc33
...
...
@@ -66,7 +66,7 @@ pProject = spstrtok "project" &> pNotSpace <&> \pn -> pProjectAction <@ Project
pPathAction
::
CParser
Char
ProjectAction
a
pPathAction
=
pPathAction
<@
ProjectPath
where
pPathAction
=
(
spstrtok
"add"
&>
pNotSpace
<@
AddPathAction
o
toString
)
<|>
(
spstrtok
"remove"
&>
nat
<@
RemovePathAction
)
<|>
(
spstrtok
"remove"
&>
sp
nat
<@
RemovePathAction
)
<|>
(
spstrtok
"list"
<@
const
ListPathsAction
)
<!>
(
pHelp
PathHelp
)
...
...
@@ -181,7 +181,7 @@ doProjectPathAction world cleanhome pn project (AddPathAction path)
#
prj
=
PR_SetPaths
False
paths
(
path
:!
paths
)
project
// TODO: Double check to see if PR_SetPaths is used correctly
#
(
ok
,
world
)
=
saveProject
cleanhome
prj
pn
world
|
not
ok
=
abort
"Failed to add path to project"
// TODO: Improve
=
world
=
showLines
[
"Path '"
+++
path
+++
"' successfully added to project"
]
world
doProjectPathAction
world
cleanhome
pn
project
(
RemovePathAction
n
)
#
paths
=
PR_GetPaths
project
...
...
@@ -189,7 +189,7 @@ doProjectPathAction world cleanhome pn project (RemovePathAction n)
#
prj
=
PR_SetPaths
False
paths
paths`
project
// TODO: Double check to see if PR_SetPaths is used correctly
#
(
ok
,
world
)
=
saveProject
cleanhome
prj
pn
world
|
not
ok
=
abort
"Failed to remove path from project"
// TODO: Improve
=
world
=
showLines
[
"Path "
+++
toString
n
+++
" successfully removed from project"
]
world
doProjectPathAction
world
_
_
project
ListPathsAction
=
showLines
[
"Paths for project:"
:
paths
]
world
where
paths
=
map
f
(
zip2
[
0
..]
(
StrictListToList
(
PR_GetPaths
project
)))
...
...
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