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
Iris
examples
Commits
ca005c1a
Commit
ca005c1a
authored
Oct 18, 2017
by
Ralf Jung
Browse files
fix pin detection
parent
140a6f0a
Changes
1
Hide whitespace changes
Inline
Side-by-side
build/opam-ci.sh
View file @
ca005c1a
...
...
@@ -51,8 +51,8 @@ while (( "$#" )); do # while there are arguments left
VERSION
=
"
$1
"
;
shift
# Check if the pin is already set
PIN
=
$(
opam pin list |
(
egrep
"^
$PACKAGE
[. ]"
||
true
)
)
if
[[
"
$
(
echo
"
$PIN
"
|
cut
-d
' '
-f
2
)
"
==
"
$KIND
"
&&
"
$(
echo
"
$PIN
"
|
cut
-d
' '
-f
3
)
"
==
"
$VERSION
"
]]
;
then
read
-a
PIN
<<<
$(
opam pin list |
(
egrep
"^
$PACKAGE
[. ]"
)
)
if
[[
"
$
{
PIN
[1]
}
"
==
"
$KIND
"
&&
"
${
PIN
[2]
}
"
==
"
$VERSION
"
]]
;
then
echo
"[opam-ci]
$PACKAGE
already
$KIND
-pinned to
$VERSION
"
else
echo
"[opam-ci]
$KIND
-pinning
$PACKAGE
to
$VERSION
"
...
...
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