File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 227227
228228 # Token for accessing the repository:
229229 token : ${{ secrets.REPO_GITHUB_TOKEN }}
230+
231+ # Checkout coverage repository branch:
232+ - name : ' Checkout coverage repository branch'
233+ run : |
234+ cd ./www-test-code-coverage
235+
236+ if [[ "${{ github.event_name }}" == "pull_request" ]]; then
237+ BRANCH_NAME="pr-${{ github.event.pull_request.number }}"
238+ git fetch origin $BRANCH_NAME || true
239+ git checkout $BRANCH_NAME || git checkout -b $BRANCH_NAME
240+ else
241+ BRANCH_NAME="main"
242+ fi
230243
231244 # Copy artifacts to the repository:
232245 - name : ' Copy artifacts to the repository'
239252 REPO_GITHUB_TOKEN : ${{ secrets.REPO_GITHUB_TOKEN }}
240253 USER_NAME : stdlib-bot
241254 run : |
242- cd ./www-test-code-coverage
243-
244- if [[ "${{ github.event_name }}" == "pull_request" ]]; then
245- BRANCH_NAME="pr-${{ github.event.pull_request.number }}"
246- git fetch origin $BRANCH_NAME || true
247- git checkout $BRANCH_NAME || git checkout -b $BRANCH_NAME
248- else
249- BRANCH_NAME="main"
250- fi
251-
252- git add .
253255 git config --local user.email "noreply@stdlib.io"
254256 git config --local user.name "stdlib-bot"
257+ git add .
255258 git commit -m "Update artifacts"
256259 git push "https://$USER_NAME:$REPO_GITHUB_TOKEN@github.com/stdlib-js/www-test-code-coverage.git" $BRANCH_NAME
257260
You can’t perform that action at this time.
0 commit comments