Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
O
osdu-ingestion-lib
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
OSDU
OSDU Data Platform
Data Flow
Data Ingestion
osdu-ingestion-lib
Commits
9d7390b1
Commit
9d7390b1
authored
3 years ago
by
Siarhei Khaletski (EPAM)
Browse files
Options
Downloads
Plain Diff
Merge branch 'GONRG-3618_Fix_local_build_setup' into 'master'
GONRG-3618: Local build setup See merge request
!4
parents
0c8eadfe
2feade1a
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!4
GONRG-3618: Local build setup
Pipeline
#75328
passed
3 years ago
Stage: linters
Stage: test
Stage: deploy
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
VERSION
+1
-1
1 addition, 1 deletion
VERSION
setup.py
+7
-3
7 additions, 3 deletions
setup.py
with
8 additions
and
4 deletions
VERSION
+
1
−
1
View file @
9d7390b1
0.1
2
.0
0.1
3
.0
This diff is collapsed.
Click to expand it.
setup.py
+
7
−
3
View file @
9d7390b1
...
...
@@ -33,9 +33,13 @@ def prepare_version():
else
:
# we assume that it is commit version
# https://packaging.python.org/guides/distributing-packages-using-setuptools/#local-version-identifiers
commit
=
os
.
environ
[
"
BUILD_COMMIT_SHORT_SHA
"
]
build_id
=
os
.
environ
[
"
BUILD_ID
"
]
version
=
f
"
{
get_version_from_file
()
}
.dev
{
build_id
}
+
{
commit
}
"
# otherwise, if there are no COMMIT_SHA and BUILD_ID, we assume it is a local build
try
:
commit
=
os
.
environ
[
"
BUILD_COMMIT_SHORT_SHA
"
]
build_id
=
os
.
environ
[
"
BUILD_ID
"
]
version
=
f
"
{
get_version_from_file
()
}
.dev
{
build_id
}
+
{
commit
}
"
except
KeyError
:
version
=
get_version_from_file
()
return
version
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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