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

fix: use master/production on merge #329

Merged
merged 1 commit into from
Nov 10, 2021
Merged

Conversation

Ali-D-Akbar
Copy link
Contributor

@Ali-D-Akbar Ali-D-Akbar commented Nov 10, 2021

PROD-2552

The previous job merge job failed due to github.head_ref not giving master on merge.

Using the same method as we did in VEM using github.ref on merge action gives you the branch name.

@codecov-commenter
Copy link

codecov-commenter commented Nov 10, 2021

Codecov Report

Merging #329 (cd7fceb) into master (86bbaa1) will not change coverage.
The diff coverage is 0.00%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #329   +/-   ##
=======================================
  Coverage   94.50%   94.50%           
=======================================
  Files          27       27           
  Lines        3000     3000           
  Branches      161      161           
=======================================
  Hits         2835     2835           
  Misses        147      147           
  Partials       18       18           
Flag Coverage Δ
unittests 94.50% <0.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
edxval/pacts/verify_pact.py 0.00% <ø> (ø)
edxval/settings/pact.py 0.00% <0.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 86bbaa1...cd7fceb. Read the comment docs.

export PUBLISH_TAGS=${{ github.head_ref }}
export GIT_ENV='development'
else
export PUBLISH_TAGS=${GITHUB_REF:11}
Copy link
Contributor

Choose a reason for hiding this comment

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

Why can't we use github.ref directly here?

Choose a reason for hiding this comment

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

Same.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

oh, it looks like we can use $GITHUB_REF directly as well. https://docs.github.com/en/actions/learn-github-actions/environment-variables

Removing the above declaration.

@ansabgillani
Copy link

One nit to be answered mentioned by Azan. Otherwise, it's good.

export PUBLISH_TAGS=${{ github.head_ref }}
if [ $IS_MERGED == false ]
then
export PUBLISH_TAGS=${{ github.head_ref }}
Copy link
Contributor

Choose a reason for hiding this comment

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

I believe we also have GITHUB_HEAD_REF, can we use it for sake of consistency?

@Ali-D-Akbar Ali-D-Akbar merged commit 8656463 into master Nov 10, 2021
@Ali-D-Akbar Ali-D-Akbar deleted the aakbar/pact-master-tag-fix branch November 10, 2021 11:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants