File tree Expand file tree Collapse file tree 1 file changed +13
-5
lines changed Expand file tree Collapse file tree 1 file changed +13
-5
lines changed Original file line number Diff line number Diff line change 33name : Push to registry
44
55on :
6- push :
6+ workflow_run :
7+ workflows : ["Integration Tests"]
8+ types :
9+ - completed
710 branches :
811 - main
9- - ' release/* '
12+ push :
1013 tags :
11- - ' *'
14+ - ' v*.*.*'
15+ - ' *.*.*'
1216 workflow_dispatch :
1317
1418env :
1721
1822jobs :
1923 build-and-push :
24+ if : |
25+ github.event_name == 'workflow_run' &&
26+ github.event.workflow_run.head_branch == 'main' &&
27+ github.event.workflow_run.event == 'push'
2028 runs-on : ubuntu-latest
2129 permissions :
2230 contents : read
5058 # For branch pushes (like main), use base version with -dev suffix and commit SHA
5159 BASE_VERSION=$(node -p "require('./package.json').version" | sed -E 's/-ea[.-][0-9]+$//')
5260 if [ "${{ github.ref }}" = "refs/heads/main" ]; then
53- SHORT_SHA=$(echo "${{ github.sha }}" | cut -c1-7 )
54- VERSION="${BASE_VERSION}-ea- ${SHORT_SHA}"
61+ SHORT_SHA=$(git rev-parse --short "${{ github.sha }}")
62+ VERSION="${BASE_VERSION}-ea. ${SHORT_SHA}"
5563 else
5664 VERSION="$BASE_VERSION"
5765 fi
You can’t perform that action at this time.
0 commit comments