Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Display commit SHA/ Release tag in the About page #2416

Merged
merged 8 commits into from
Jun 19, 2018
Merged

Conversation

irfanhabib
Copy link
Contributor

@irfanhabib irfanhabib commented Jun 18, 2018

fixes #2410

@cfdreddbot
Copy link

Hey irfanhabib!

Thanks for submitting this pull request! I'm here to inform the recipients of the pull request that you and the commit authors have already signed the CLA.

@codecov
Copy link

codecov bot commented Jun 18, 2018

Codecov Report

Merging #2416 into v2-master will increase coverage by 0.01%.
The diff coverage is 72.68%.

@@              Coverage Diff              @@
##           v2-master    #2416      +/-   ##
=============================================
+ Coverage      71.04%   71.06%   +0.01%     
=============================================
  Files            583      585       +2     
  Lines          24452    24539      +87     
  Branches        5483     5508      +25     
=============================================
+ Hits           17373    17438      +65     
- Misses          7079     7101      +22

@@ -18,7 +18,7 @@ DEPLOY_PATH=${STRATOS_UI_PATH}/deploy

NO_UI=false
CLEAN=false

STRATOS_VERSION=v2.0.0-$(git log -1 --format="%h")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we remove the v so its 2.0.0 ... We should read the 2.0.0 part from the package file, otherwise we'll need to update this everytime we release 2.0.1 etc.

@@ -18,12 +18,13 @@ function env_vars {
pushd "${DEPLOYDIR}"
ls
env_vars

STRATOS_VERSION=v2.0.0-$(git log -1 --format="%h")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove v

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should read the 2.0.0 part from the package file, otherwise we'll need to update this everytime we release 2.0.1 etc.

@@ -18,7 +18,8 @@ DEPLOY_PATH=${STRATOS_UI_PATH}/deploy

NO_UI=false
CLEAN=false

PACKAGE_JSON_VERSION=$(cat ${STRATOS_UI_PATH}/package.json | grep version | grep -Po "([0-9\.]?)*")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This does not work on Mac - grep -P not supported I think. Not sure about Windows either

Copy link
Contributor

@nwmac nwmac Jun 18, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will work on the mac for the grep command:

grep -Eo "([0-9]*.[0-9]*.[0-9]*)"

@irfanhabib
Copy link
Contributor Author

@nwmac Updated!

Copy link
Contributor

@nwmac nwmac left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@nwmac nwmac merged commit 28a14b5 into v2-master Jun 19, 2018
@nwmac nwmac deleted the add-version branch June 19, 2018 11:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add commit SHA to version when built for Kubernetes/Docker Compose
3 participants