|
11 | 11 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
12 | 12 | IS_OFFICIAL_REPO: ${{ github.repository == 'temporalio/sdk-typescript' }} |
13 | 13 | # Is it the official main branch, or an official release branches? |
14 | | - IS_MAIN_OR_RELEASE: | |
15 | | - ${{ |
16 | | - github.repository == 'temporalio/sdk-typescript' |
17 | | - && (github.ref == 'refs/heads/main' |
18 | | - || startsWith(github.ref, 'refs/tags/') |
19 | | - || startsWith(github.ref, 'refs/heads/releases')) |
20 | | - && github.event_name != 'pull_request' |
21 | | - }} |
| 14 | + # AFAIK there's no way to break that line w/o introducing a trailing LF that breaks usage. Sorry. |
| 15 | + IS_MAIN_OR_RELEASE: ${{ github.repository == 'temporalio/sdk-typescript' && ( github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/') || startsWith(github.ref, 'refs/heads/releases')) && github.event_name != 'pull_request' }} |
| 16 | + |
22 | 17 | # Use these variables to force specific version of CLI/Time Skipping Server for SDK tests |
23 | 18 | # TESTS_CLI_VERSION: 'v0.13.2' |
24 | 19 | # TESTS_TIME_SKIPPING_SERVER_VERSION: 'v1.24.1' |
@@ -105,7 +100,7 @@ jobs: |
105 | 100 | prefix-key: corebridge-buildcache |
106 | 101 | shared-key: ${{ matrix.platform }} |
107 | 102 | env-vars: '' |
108 | | - save-if: env.IS_MAIN_OR_RELEASE == 'true' |
| 103 | + save-if: ${{ env.IS_MAIN_OR_RELEASE == 'true' }} |
109 | 104 |
|
110 | 105 | - name: Compile rust code |
111 | 106 | if: steps.cached-artifact.outputs.cache-hit != 'true' |
@@ -203,7 +198,7 @@ jobs: |
203 | 198 | - name: Save NPM cache |
204 | 199 | uses: actions/cache/save@v4 |
205 | 200 | # Only saves NPM cache from the main branch, to reduce pressure on the cache (limited to 10GB). |
206 | | - if: env.IS_MAIN_OR_RELEASE == 'true' |
| 201 | + if: ${{ env.IS_MAIN_OR_RELEASE == 'true' }} |
207 | 202 | with: |
208 | 203 | path: ${{ steps.npm-cache-dir.outputs.dir }} |
209 | 204 | key: npm-main-${{ matrix.platform }}-${{ hashFiles('./package-lock.json') }} |
@@ -571,7 +566,7 @@ jobs: |
571 | 566 | ALGOLIA_API_KEY: ${{ secrets.ALGOLIA_API_KEY }} |
572 | 567 |
|
573 | 568 | - name: Deploy prod docs # TODO: only deploy prod docs when we publish a new version |
574 | | - if: env.IS_MAIN_OR_RELEASE == 'true' |
| 569 | + if: ${{ env.IS_MAIN_OR_RELEASE == 'true' }} |
575 | 570 | run: npx vercel deploy packages/docs/build -t ${{ secrets.VERCEL_TOKEN }} --name typescript --scope temporal --prod --yes |
576 | 571 |
|
577 | 572 | # FIXME: This is not working properly, and should probably be done only from the main branch anyway |
|
0 commit comments