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
taste-setup
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
2
Issues
2
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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
TASTE
taste-setup
Commits
8d2a377e
Commit
8d2a377e
authored
Aug 09, 2017
by
Thanassis Tsiodras
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Shellcheck pass - and use proper logic for git repo status check
parent
0a741877
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
69 additions
and
38 deletions
+69
-38
install/40_ocarina.sh
install/40_ocarina.sh
+10
-6
install/50_opengeode.sh
install/50_opengeode.sh
+11
-5
install/53_pymsc.sh
install/53_pymsc.sh
+9
-5
install/54_speedometer.sh
install/54_speedometer.sh
+9
-5
install/55_asn1valueEditor.sh
install/55_asn1valueEditor.sh
+10
-5
install/56_msc-editor.sh
install/56_msc-editor.sh
+9
-6
install/60_buildsupport.sh
install/60_buildsupport.sh
+11
-6
No files found.
install/40_ocarina.sh
View file @
8d2a377e
#!/bin/bash
DIR
=
"
$(
cd
"
$(
dirname
"
${
BASH_SOURCE
[0]
}
"
)
"
&&
pwd
)
"
.
${
DIR
}
/common.sh
.
"
${
DIR
}
/common.sh"
# Setup the tools in ~/.local/bin
cd
$DIR
/../ocarina
||
exit
1
cd
"
$DIR
/../ocarina"
||
exit
1
# Skip Ocarina building if tree is clean and version is identical
HEAD
=
"
$(
git log
--oneline
|
head
-1
|
cut
-d
' '
-f1
)
"
VERSION_INSTALLED
=
"
$(
ocarina
-v
2>&1 |
grep
^Oca |
awk
'{print $NF}'
|
sed
's,),,;s,r,,'
)
"
git status
>
/dev/null
TREE_CLEAN
=
$?
if
[
${
TREE_CLEAN
}
-eq
0
-a
"
${
HEAD
}
"
==
"
${
VERSION_INSTALLED
}
"
]
;
then
GIT_OUTPUT
=
$(
git status
--porcelain
)
if
[
"
${
GIT_OUTPUT
}
"
==
""
]
;
then
TREE_DIRTY
=
0
else
TREE_DIRTY
=
1
fi
if
[
${
TREE_DIRTY
}
-eq
0
]
&&
[
"
${
HEAD
}
"
==
"
${
VERSION_INSTALLED
}
"
]
;
then
echo
Ocarina tree is clean and already installed. Skipping Ocarina build...
exit
0
fi
make distclean
# ignore any errors here
./support/reconfig
||
exit
1
./configure
--prefix
=
${
PREFIX
}
||
exit
1
./configure
--prefix
=
"
${
PREFIX
}
"
||
exit
1
make
||
exit
1
make
install
...
...
install/50_opengeode.sh
View file @
8d2a377e
#!/bin/bash
DIR
=
"
$(
cd
"
$(
dirname
"
${
BASH_SOURCE
[0]
}
"
)
"
&&
pwd
)
"
.
${
DIR
}
/common.sh
.
"
${
DIR
}
/common.sh"
# Setup opengeode in ~/.local/bin
cd
$DIR
/../opengeode
||
exit
1
cd
"
$DIR
/../opengeode"
||
exit
1
# Skip install if the version installed is the same and the tree is clean
HEAD
=
"
$(
grep
_version_ opengeode/opengeode.py |
head
-1
|
awk
-F
\'
'{print $2}'
)
"
VERSION_INSTALLED
=
"
$(
opengeode
--version
2>&1
)
"
git status
>
/dev/null
TREE_CLEAN
=
$?
if
[
${
TREE_CLEAN
}
-eq
0
-a
"
${
HEAD
}
"
==
"
${
VERSION_INSTALLED
}
"
]
;
then
GIT_OUTPUT
=
$(
git status
--porcelain
)
if
[
"
${
GIT_OUTPUT
}
"
==
""
]
;
then
TREE_DIRTY
=
0
else
TREE_DIRTY
=
1
fi
if
[
${
TREE_DIRTY
}
-eq
0
]
&&
[
"
${
HEAD
}
"
==
"
${
VERSION_INSTALLED
}
"
]
;
then
echo
OpenGEODE tree is clean and already installed. Skipping OpenGEODE install...
exit
0
fi
...
...
install/53_pymsc.sh
View file @
8d2a377e
#!/bin/bash
DIR
=
"
$(
cd
"
$(
dirname
"
${
BASH_SOURCE
[0]
}
"
)
"
&&
pwd
)
"
.
${
DIR
}
/common.sh
.
"
${
DIR
}
/common.sh"
# Setup pymsc in ~/.local
cd
$DIR
/../pymsc
||
exit
1
cd
"
$DIR
/../pymsc"
||
exit
1
# Skip install if the version installed is the same and the tree is clean
HEAD
=
"
$(
grep
__version msccore/__init__.py |
awk
'{print $NF}'
|
tr
-d
'"'
)
"
VERSION_INSTALLED
=
"
$(
pip2 freeze |
grep
taste-msc |
awk
-F
=
'{print $NF}'
)
"
git status
>
/dev/null
TREE_CLEAN
=
$?
if
[
${
TREE_CLEAN
}
-eq
0
-a
"
${
HEAD
}
"
==
"
${
VERSION_INSTALLED
}
"
]
;
then
GIT_OUTPUT
=
$(
git status
--porcelain
)
if
[
"
${
GIT_OUTPUT
}
"
==
""
]
;
then
TREE_DIRTY
=
0
else
TREE_DIRTY
=
1
fi
if
[
${
TREE_DIRTY
}
-eq
0
]
&&
[
"
${
HEAD
}
"
==
"
${
VERSION_INSTALLED
}
"
]
;
then
echo
taste-msc tree is clean and already installed. Skipping taste-msc install...
exit
0
fi
...
...
install/54_speedometer.sh
View file @
8d2a377e
#!/bin/bash
DIR
=
"
$(
cd
"
$(
dirname
"
${
BASH_SOURCE
[0]
}
"
)
"
&&
pwd
)
"
.
${
DIR
}
/common.sh
.
"
${
DIR
}
/common.sh"
# Setup speedometer library in ~/.local
cd
$DIR
/../speedometer
||
exit
1
cd
"
$DIR
/../speedometer"
||
exit
1
# Skip install if the version installed is the same and the tree is clean
HEAD
=
"
$(
grep
version speedometer/speedometer.py |
head
-1
|
awk
-F
\"
'{print $(NF-1)}'
)
"
# This is much slower than a --version option would be...
# But there's no such functionality in speedometer :-(
VERSION_INSTALLED
=
"
$(
pip2 freeze |
grep
speedometer |
awk
-F
=
'{print $NF}'
)
"
GIT_OUTPUT
=
$(
git status
--porcelain
)
if
[
"
${
GIT_OUTPUT
}
"
==
""
]
;
then
TREE_DIRTY
=
0
else
TREE_DIRTY
=
1
fi
git status
>
/dev/null
TREE_CLEAN
=
$?
if
[
${
TREE_CLEAN
}
-eq
0
-a
"
${
HEAD
}
"
==
"
${
VERSION_INSTALLED
}
"
]
;
then
if
[
${
TREE_DIRTY
}
-eq
0
]
&&
[
"
${
HEAD
}
"
==
"
${
VERSION_INSTALLED
}
"
]
;
then
echo
Speedometer tree is clean and already installed. Skipping Speedometer install...
exit
0
fi
...
...
install/55_asn1valueEditor.sh
View file @
8d2a377e
#!/bin/bash
DIR
=
"
$(
cd
"
$(
dirname
"
${
BASH_SOURCE
[0]
}
"
)
"
&&
pwd
)
"
.
${
DIR
}
/common.sh
.
"
${
DIR
}
/common.sh"
# Setup asn1valueEditor in ~/.local/bin
cd
$DIR
/../asn1-value-editor
||
exit
1
cd
"
$DIR
/../asn1-value-editor"
||
exit
1
# Skip install if the version installed is the same and the tree is clean
HEAD
=
"
$(
grep
__version asn1_value_editor/asn1_value_editor.py |
head
-1
|
awk
-F
\"
'{print $(NF-1);}'
)
"
VERSION_INSTALLED
=
"
$(
taste-gui
--version
2>&1 |
head
-1
|
awk
'{print $NF}'
)
"
git status
>
/dev/null
TREE_CLEAN
=
$?
if
[
${
TREE_CLEAN
}
-eq
0
-a
"
${
HEAD
}
"
==
"
${
VERSION_INSTALLED
}
"
]
;
then
GIT_OUTPUT
=
$(
git status
--porcelain
)
if
[
"
${
GIT_OUTPUT
}
"
==
""
]
;
then
TREE_DIRTY
=
0
else
TREE_DIRTY
=
1
fi
if
[
${
TREE_DIRTY
}
-eq
0
]
&&
[
"
${
HEAD
}
"
==
"
${
VERSION_INSTALLED
}
"
]
;
then
echo
ASN.1 Value Editor tree is clean and already installed. Skipping asn1valueEditor install...
exit
0
fi
...
...
install/56_msc-editor.sh
View file @
8d2a377e
#!/bin/bash
DIR
=
"
$(
cd
"
$(
dirname
"
${
BASH_SOURCE
[0]
}
"
)
"
&&
pwd
)
"
.
${
DIR
}
/common.sh
.
"
${
DIR
}
/common.sh"
# Setup the tools in ~/.local/bin
cd
$DIR
/../msc-editor
||
exit
1
cd
"
$DIR
/../msc-editor"
||
exit
1
# Skip install if the version installed is the same and the tree is clean
HEAD
=
"
$(
grep
__version msce/msce.py |
head
-1
|
awk
-F
\'
'{print $(NF-1)}'
)
"
# This is much slower than a --version option would be...
# But there's no such functionality in msc-editor :-(
VERSION_INSTALLED
=
"
$(
pip2 freeze |
grep
msce |
awk
-F
=
'{print $NF}'
)
"
GIT_OUTPUT
=
$(
git status
--porcelain
)
if
[
"
${
GIT_OUTPUT
}
"
==
""
]
;
then
TREE_DIRTY
=
0
else
TREE_DIRTY
=
1
fi
git status
>
/dev/null
TREE_CLEAN
=
$?
if
[
${
TREE_CLEAN
}
-eq
0
-a
"
${
HEAD
}
"
==
"
${
VERSION_INSTALLED
}
"
]
;
then
if
[
${
TREE_DIRTY
}
-eq
0
]
&&
[
"
${
HEAD
}
"
==
"
${
VERSION_INSTALLED
}
"
]
;
then
echo
MSC editor tree is clean and already installed. Skipping MSCE install...
exit
0
fi
...
...
install/60_buildsupport.sh
View file @
8d2a377e
#!/bin/bash
DIR
=
"
$(
cd
"
$(
dirname
"
${
BASH_SOURCE
[0]
}
"
)
"
&&
pwd
)
"
.
${
DIR
}
/common.sh
.
"
${
DIR
}
/common.sh"
# Setup the tools in ~/.local/bin
cd
$DIR
/../buildsupport
||
exit
1
cd
"
$DIR
/../buildsupport"
||
exit
1
# Skip Ocarina building if tree is clean and version is identical
HEAD
=
"
$(
git log
--oneline
|
head
-1
|
cut
-d
' '
-f1
)
"
VERSION_INSTALLED
=
"
$(
buildsupport
-v
2>&1 |
grep
Version |
cut
-f
4
-d
' '
|
tr
-d
'\012'
)
"
git status
>
/dev/null
TREE_CLEAN
=
$?
if
[
${
TREE_CLEAN
}
-eq
0
-a
"
${
HEAD
}
"
==
"
${
VERSION_INSTALLED
}
"
]
;
then
GIT_OUTPUT
=
$(
git status
--porcelain
)
if
[
"
${
GIT_OUTPUT
}
"
==
""
]
;
then
TREE_DIRTY
=
0
else
TREE_DIRTY
=
1
fi
if
[
${
TREE_DIRTY
}
-eq
0
]
&&
[
"
${
HEAD
}
"
==
"
${
VERSION_INSTALLED
}
"
]
;
then
echo
Buildsupport tree is clean and already installed. Skipping Buildsupport build...
exit
0
fi
make clean
# ignore any errors here
make
||
exit
1
cp
buildsupport
${
PREFIX
}
/bin
||
exit
1
cp
buildsupport
"
${
PREFIX
}
/bin"
||
exit
1
# Add Ocarina to PATH
PATH_CMD
=
'export PATH=$PATH:'
"
${
PREFIX
}
/bin"
...
...
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