Skip to content

Commit 920171c

Browse files
committed
fix build and run ci
1 parent 3558ee1 commit 920171c

File tree

2 files changed

+38
-26
lines changed

2 files changed

+38
-26
lines changed

.github/workflows/build.yml

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
name: build
2+
on: [pull_request]
3+
jobs:
4+
golangci-lint:
5+
name: runner / build_and_run
6+
runs-on: ubuntu-latest
7+
steps:
8+
- name: Check out code into the Go module directory
9+
uses: actions/checkout@v2
10+
- uses: actions/setup-go@v2
11+
with:
12+
go-version: 1.17
13+
- name: Install JRE
14+
run: |
15+
sudo apt update && sudo apt install openjdk-17-jre
16+
- uses: actions/setup-node@v2
17+
with:
18+
node-version: "16"
19+
cache: "npm"
20+
cache-dependency-path: package-lock.json
21+
- name: Install emulator
22+
run: |
23+
npm ci
24+
- name: Run emulator
25+
run: |
26+
make emulator &
27+
- name: Ensure samples are generated
28+
env:
29+
TZ: Asia/Tokyo
30+
run: |
31+
make gen_samples
32+
33+
clean=$(git status | grep "nothing to commit" || true)
34+
if [ -z "$clean" ]; then
35+
git diff
36+
echo 'Please run "make gen_samples"'
37+
exit 1
38+
fi

.github/workflows/linter.yml

Lines changed: 0 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -10,32 +10,6 @@ jobs:
1010
- uses: actions/setup-go@v2
1111
with:
1212
go-version: 1.17
13-
- name: Install JRE
14-
run: |
15-
sudo apt update && sudo apt install openjdk-17-jre
16-
- uses: actions/setup-node@v2
17-
with:
18-
node-version: "16"
19-
cache: "npm"
20-
cache-dependency-path: package-lock.json
21-
- name: Install emulator
22-
run: |
23-
npm ci
24-
- name: Run emulator
25-
run: |
26-
make emulator &
27-
- name: Ensure samples are generated
28-
env:
29-
TZ: Asia/Tokyo
30-
run: |
31-
make gen_samples
32-
33-
clean=$(git status | grep "nothing to commit" || true)
34-
if [ -z "$clean" ]; then
35-
git diff
36-
echo 'Please run "make gen_samples"'
37-
exit 1
38-
fi
3913
- name: golangci-lint
4014
uses: golangci/golangci-lint-action@v2
4115
with:

0 commit comments

Comments
 (0)