Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
portal-backend
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
HBP Medical Informatics Platform
portal-backend
Commits
1666fdf1
Commit
1666fdf1
authored
7 years ago
by
Mirco
Browse files
Options
Downloads
Patches
Plain Diff
fix build script for CircleCI
parent
fcf39c34
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
.bumpversion.cfg
+0
-1
0 additions, 1 deletion
.bumpversion.cfg
build.sh
+9
-8
9 additions, 8 deletions
build.sh
with
9 additions
and
9 deletions
.bumpversion.cfg
+
0
−
1
View file @
1666fdf1
...
...
@@ -11,4 +11,3 @@ search = <version>{current_version}</version><!-- BUMP_VERSION -->
replace
= <version>{new_version}</version><!-- BUMP_VERSION -->
[bumpversion:file:hbp.yml]
This diff is collapsed.
Click to expand it.
build.sh
+
9
−
8
View file @
1666fdf1
#!/usr/bin/env bash
set
-e
set
-o
pipefail
# trace ERR through pipes
set
-o
errtrace
# trace ERR through 'time command' and other functions
set
-o
errexit
## set -e : exit the script if any statement returns a non-true return value
get_script_dir
()
{
SOURCE
=
"
${
BASH_SOURCE
[0]
}
"
...
...
@@ -13,19 +16,17 @@ get_script_dir () {
pwd
}
if
pgrep
-lf
sshuttle
>
/dev/null
;
then
echo
"sshuttle detected. Please close this program as it messes with networking and prevents builds inside Docker to work"
exit
1
fi
cd
"
$(
get_script_dir
)
"
if
groups
$USER
|
grep
&>/dev/null
'\bdocker\b'
;
then
if
[[
$NO_SUDO
||
-n
"
$CIRCLECI
"
]]
;
then
CAPTAIN
=
"captain"
elif
groups
$USER
|
grep
&>/dev/null
'\bdocker\b'
;
then
CAPTAIN
=
"captain"
else
CAPTAIN
=
"sudo captain"
fi
BUILD_DATE
=
$(
date
-
-iso-8601
=
seconds
)
\
BUILD_DATE
=
$(
date
-
I
seconds
)
\
VCS_REF
=
$(
git describe
--tags
--dirty
)
\
VERSION
=
$(
git describe
--tags
--dirty
)
\
WORKSPACE
=
$(
get_script_dir
)
\
$CAPTAIN
build
This diff is collapsed.
Click to expand it.
Preview
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!
Save comment
Cancel
Please
register
or
sign in
to comment