Skip to content

Commit f26b18d

Browse files
committed
add ci
1 parent b7f7e83 commit f26b18d

2 files changed

Lines changed: 78 additions & 0 deletions

File tree

.github/workflows/publish.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: publish-package
2+
run-name: publish to mooncakes
3+
on: workflow_dispatch
4+
jobs:
5+
publish:
6+
runs-on: ubuntu-latest
7+
steps:
8+
- uses: actions/checkout@v4
9+
- name: install
10+
run: |
11+
curl -fsSL https://cli.moonbitlang.com/install/unix.sh | bash
12+
echo "$HOME/.moon/bin" >> $GITHUB_PATH
13+
- name: moon version
14+
run: |
15+
moon version --all
16+
- name: moon update
17+
run: |
18+
moon update
19+
- name: moon check
20+
run: |
21+
moon check --target native
22+
- name: publish
23+
run: |
24+
echo $SECRET > ~/.moon/credentials.json
25+
moon publish
26+
rm ~/.moon/credentials.json
27+
env:
28+
SECRET: ${{ secrets.MOONCAKES_MOONBIT_COMMUNITY_TOKEN }}

.github/workflows/stable_check.yml

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
name: check
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
9+
jobs:
10+
check:
11+
strategy:
12+
fail-fast: false
13+
runs-on: ubuntu-latest
14+
continue-on-error: false
15+
steps:
16+
- uses: actions/checkout@v4
17+
18+
- name: install
19+
run: |
20+
curl -fsSL https://cli.moonbitlang.com/install/unix.sh | bash
21+
echo "$HOME/.moon/bin" >> $GITHUB_PATH
22+
23+
- name: moon version
24+
run: |
25+
moon version --all
26+
27+
- name: moon update
28+
run: |
29+
moon update
30+
31+
- name: moon check
32+
run: moon check
33+
34+
- name: format diff
35+
run: |
36+
moon fmt
37+
git diff --exit-code
38+
39+
- name: info check
40+
run: |
41+
moon info
42+
git diff --exit-code
43+
44+
- name: Set ulimit
45+
run: |
46+
ulimit -s 8176
47+
48+
- name: moon test
49+
run: |
50+
moon test --target all

0 commit comments

Comments
 (0)