-
-
Notifications
You must be signed in to change notification settings - Fork 1
49 lines (42 loc) · 1.34 KB
/
create_config.yml
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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
name: Create quickget configs
on:
schedule:
- cron: '58 23 * * *'
workflow_dispatch:
repository_dispatch:
types: [ generate_configuration ]
jobs:
create_configs:
permissions:
contents: write
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
repository: 'lj3954/quickemu-rs'
- name: Restore cache
uses: actions/cache/restore@v4
with:
path: target/release/quickget_ci
key: ${{ runner.os }}-quickget_ci-${{ hashFiles('**/Cargo.lock') }}
- name: Install zstd
run: sudo apt-get install -y zstd
- name: Create configs
run: |
/target/release/quickget_ci
zstd -19 -o quickget_data.json.zst quickget_data.json
gzip -9 -k quickget_data.json
- name: Commit uncompressed JSON
uses: amousavigourabi/push-action@v0
with:
message: 'ci: update quickget configurations'
branch: main
files: 'quickget_data.json'
- name: Release archives
uses: ncipollo/release-action@v1
with:
allowUpdates: true
artifacts: 'quickget_data.json.zst, quickget_data.json.gz'
artifactContentType: 'application/octet-stream'
body: 'Quickget configuration files (Compressed)'
token: ${{ secrets.GITHUB_TOKEN }}