Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 05152be commit bc9f440Copy full SHA for bc9f440
.github/workflows/preview.yaml
@@ -5,9 +5,21 @@ on: [pull_request]
5
permissions:
6
pull-requests: write # allow surge-preview to create/update PR comments
7
8
+concurrency:
9
+ group: ${{ github.workflow }}-${{ github.ref }}
10
+ cancel-in-progress: true
11
+
12
+env:
13
+ PREVIEW_URL: 'https://github.com/{{ github.repository }}-{{ github.job }}-pr-{{ github.event.number }}.surge.sh'
14
+ PRODUCTION_URL: 'https://tutorial.xarray.dev/'
15
16
jobs:
17
preview:
18
runs-on: ubuntu-latest
19
+ environment:
20
+ name: ${{ github.ref == 'refs/heads/main' && 'production' || 'preview' }}
21
+ url: ${{ github.ref == 'refs/heads/main' && env.PRODUCTION_URL || env.PREVIEW_URL }}
22
23
steps:
24
- name: Checkout repository
25
uses: actions/checkout@v3
0 commit comments