Skip to content

Commit

Permalink
Update main.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
jiaojiaodubai committed Apr 18, 2024
1 parent 8a94e3a commit b349520
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ on:
branches:
- master
- test

paths:
- '*.js'
workflow_dispatch:
jobs:
build:
Expand All @@ -13,12 +16,7 @@ jobs:
- name: 'Checkout codes'
uses: actions/checkout@v3

# We're in a shallow single-branch clone, so get the origin/master HEAD if not already on master
# and get more history on the current branch so we can find the branch point
# fix fatal: ambiguous argument 'HEAD~1': unknown revision or path not in the working tree.
- run: git fetch origin master:master --depth=1
if: github.ref != 'refs/heads/master'
- run: git fetch --update-shallow --depth=100 origin $(git rev-list HEAD)
- run: git fetch origin master:master

- name: Install Node
uses: actions/setup-node@v2
Expand Down

0 comments on commit b349520

Please sign in to comment.