-
Notifications
You must be signed in to change notification settings - Fork 0
35 lines (26 loc) · 872 Bytes
/
Copy pathlint.yml
File metadata and controls
35 lines (26 loc) · 872 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
name: Lint and test
on:
push
jobs:
run-linter:
runs-on: ubuntu-latest
steps:
- name: Check out Git repository
uses: actions/checkout@v2
- name: Set up Node.js
uses: actions/setup-node@v1
with:
node-version: 17
- name: Init docker swarm
run: docker swarm init
- name: Install Node.js dependencies
run: yarn install
- name: Lint and format
run: yarn format
- name: Setup git config
run: |
# setup the username and email. I tend to use 'GitHub Actions Bot' with no email by default
git config user.name "GitHub Actions Bot"
git config user.email "<>"
- name: Commit Linting Fixes
run: git diff-index --quiet HEAD || (git commit -a -m'[bot] auto fix' --allow-empty && git push -f)