File tree Expand file tree Collapse file tree 1 file changed +12
-8
lines changed Expand file tree Collapse file tree 1 file changed +12
-8
lines changed Original file line number Diff line number Diff line change 3
3
on :
4
4
push :
5
5
branches : [ main ]
6
+ tags : [ 'v*.*.*' ]
6
7
pull_request :
7
8
branches : [ main, dev ]
8
9
11
12
runs-on : ubuntu-latest
12
13
steps :
13
14
- name : Checkout mc-mcp
14
- uses : actions/checkout@v3
15
+ uses : actions/checkout@v4
15
16
16
17
- name : Set up Rust
17
18
uses : actions-rs/toolchain@v1
@@ -39,14 +40,18 @@ jobs:
39
40
- name : Run tests
40
41
run : cargo test --all --release
41
42
42
- build-prebuilt-index :
43
+ build-and-release-index :
44
+ needs : build-and-test
45
+ if : startsWith(github.ref, 'refs/tags/')
43
46
runs-on : ubuntu-latest
47
+ permissions :
48
+ contents : write
44
49
steps :
45
50
- name : Checkout mc-mcp
46
- uses : actions/checkout@v3
51
+ uses : actions/checkout@v4
47
52
48
53
- name : Checkout metacontract-docs
49
- uses : actions/checkout@v3
54
+ uses : actions/checkout@v4
50
55
with :
51
56
repository : metacontract/mc
52
57
path : mc
66
71
- name : Compress index
67
72
run : gzip -9 -f artifacts/prebuilt_index.jsonl
68
73
69
- - name : Upload prebuilt index artifact
70
- uses : actions/upload-artifact@v4
74
+ - name : Create Release and Upload Asset
75
+ uses : softprops/action-gh-release@v1
71
76
with :
72
- name : prebuilt_index.jsonl.gz
73
- path : artifacts/prebuilt_index.jsonl.gz
77
+ files : artifacts/prebuilt_index.jsonl.gz
You can’t perform that action at this time.
0 commit comments