File tree Expand file tree Collapse file tree 2 files changed +21
-22
lines changed Expand file tree Collapse file tree 2 files changed +21
-22
lines changed Original file line number Diff line number Diff line change 9
9
secrets :
10
10
NX_CLOUD_ACCESS_TOKEN : ${{ secrets.NX_CLOUD_ACCESS_TOKEN }}
11
11
12
- e2e-test :
13
- needs : [test]
14
- uses : ./.github/workflows/e2e-test.yaml
15
- secrets :
16
- NX_CLOUD_ACCESS_TOKEN : ${{ secrets.NX_CLOUD_ACCESS_TOKEN }}
17
-
18
- build :
19
- needs : [test, e2e-test]
20
- uses : ./.github/workflows/build.yml
21
- secrets :
22
- NX_CLOUD_ACCESS_TOKEN : ${{ secrets.NX_CLOUD_ACCESS_TOKEN }}
12
+ # e2e-test:
13
+ # needs: [test]
14
+ # uses: ./.github/workflows/e2e-test.yaml
15
+ # secrets:
16
+ # NX_CLOUD_ACCESS_TOKEN: ${{ secrets.NX_CLOUD_ACCESS_TOKEN }}
17
+ #
18
+ # build:
19
+ # needs: [test, e2e-test]
20
+ # uses: ./.github/workflows/build.yml
21
+ # secrets:
22
+ # NX_CLOUD_ACCESS_TOKEN: ${{ secrets.NX_CLOUD_ACCESS_TOKEN }}
Original file line number Diff line number Diff line change @@ -26,21 +26,20 @@ jobs:
26
26
- name : Setup Node.js
27
27
uses : ./.github/actions
28
28
29
- - name : Determine base branch for NX affected
30
- id : set-base
29
+ - name : Determine base for NX affected (if not master)
30
+ if : ${{ github.event.inputs.mainBranch != 'master' }}
31
31
shell : bash
32
32
run : |
33
- if [ "${{ github.event.inputs.mainBranch }}" = "master" ]; then
34
- echo "base=master" >> $GITHUB_OUTPUT
35
- echo "Using base branch 'master'"
36
- else
37
- LAST_TAG=$(git describe --tags --abbrev=0)
38
- LAST_TAG_HASH=$(git rev-parse "$LAST_TAG")
39
- echo "base=$LAST_TAG_HASH" >> $GITHUB_OUTPUT
40
- echo "Using last tag hash: $LAST_TAG_HASH"
41
- fi
33
+ LAST_TAG=$(git describe --tags --abbrev=0)
34
+ LAST_TAG_HASH=$(git rev-parse "$LAST_TAG")
35
+ CURRENT_COMMIT=$(git rev-parse HEAD)
36
+ echo "Using last tag hash as NX_BASE: $LAST_TAG_HASH"
37
+ echo "Using current commit as NX_HEAD: $CURRENT_COMMIT"
38
+ echo "NX_BASE=$LAST_TAG_HASH" >> $GITHUB_ENV
39
+ echo "NX_HEAD=$CURRENT_COMMIT" >> $GITHUB_ENV
42
40
43
41
- name : Derive appropriate SHAs for base and head for `nx affected` commands
42
+ if : ${{ github.event.inputs.mainBranch == 'master' }}
44
43
uses : nrwl/nx-set-shas@v4
45
44
with :
46
45
main-branch-name : ${{ steps.set-base.outputs.base }}
You can’t perform that action at this time.
0 commit comments