Fix build for forks. (#3116)

Co-authored-by: Catenocrypt <catenocrypt@users.noreply.github.com>
This commit is contained in:
Adam R 2020-08-07 10:56:27 +02:00 committed by GitHub
parent 319db19d4f
commit 5d8ed57d09
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 20 additions and 55 deletions

View File

@ -3,7 +3,7 @@ on:
push:
branches: [ master ]
jobs:
test:
check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

View File

@ -1,9 +1,5 @@
name: Fixes and Consistency Updates - Dry run
on:
push:
branches:
- '*'
- '!master'
pull_request:
branches: [master]
jobs:
@ -18,9 +14,10 @@ jobs:
run: npm ci
- name: Run fix script
run: npm run fix
- name: Show fix result (diff); run 'npm run fix' locally
if: success()
run: git status
- name: Show fix result (diff); run 'npm run fix' locally
run: |
git status
git diff
- name: Run check
run: npm run check
- name: Run test

View File

@ -1,17 +1,15 @@
name: Fixes and Consistency Updates - PR
name: Fixes and Consistency Updates - Fork
on:
push:
branches:
- '*'
- '!master'
pull_request-target
branches-ignore: ['trustwallet/*']
jobs:
fix-pr:
fix-fork:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
token: ${{ secrets.GITHUB_TOKEN }}
ref: ${{ github.ref }}
- uses: actions/setup-node@v1
with:
node-version: 12
@ -20,7 +18,9 @@ jobs:
- name: Run fix script
run: npm run fix
- name: Show fix result (diff); run 'npm run fix' locally
run: git status
run: |
git status
git diff
- name: Run check
run: npm run check
- name: Run test
@ -31,4 +31,4 @@ jobs:
with:
commit_user_name: trust-wallet-merge-bot
commit_user_email: mergebot@trustwallet.com
commit_message: Fixes and Consistency Updates PR
commit_message: Fixes and Consistency Updates on a Fork

View File

@ -1,35 +0,0 @@
name: Fixes and Consistency Updates - PR
on:
push:
branches:
- '*'
- '!master'
pull_request:
branches: [master]
jobs:
fix-pr:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
token: ${{ secrets.GITHUB_TOKEN }}
- uses: actions/setup-node@v1
with:
node-version: 12
- name: Install Dependencies
run: npm ci
- name: Run fix script
run: npm run fix
- name: Show fix result (diff); run 'npm run fix' locally
run: git status
- name: Run check
run: npm run check
- name: Run test
run: npm t
- name: Commit changes if any
if: success()
uses: stefanzweifel/git-auto-commit-action@v4.1.2
with:
commit_user_name: trust-wallet-merge-bot
commit_user_email: mergebot@trustwallet.com
commit_message: Fixes and Consistency Updates PR

View File

@ -1,7 +1,7 @@
name: Fixes and Consistency Updates
on:
push:
branches: [ master ]
branches: [ 'trustwallet/master' ]
jobs:
fix:
runs-on: ubuntu-latest
@ -9,7 +9,7 @@ jobs:
- uses: actions/checkout@v2
with:
token: ${{ secrets.DANGER_GITHUB_API_TOKEN }}
ref: ${{ github.head_ref }}
ref: ${{ github.ref }}
- uses: actions/setup-node@v1
with:
node-version: 12
@ -18,7 +18,9 @@ jobs:
- name: Run fix script
run: npm run fix
- name: Show fix result (diff); run 'npm run fix' locally
run: git status
run: |
git status
git diff
- name: Run check
run: npm run check
- name: Run test

View File

@ -17,4 +17,5 @@ jobs:
- uses: bahmutov/npm-install@v1
- name: Run check
run: npm run check
- run: npm t
- name: Run test
run: npm t