-
Notifications
You must be signed in to change notification settings - Fork 6
72 lines (67 loc) · 2.14 KB
/
build-cpu-static-linux-x64.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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
name: Build CPU Static Linux X64
permissions:
contents: write
# Controls when the action will run.
on:
push:
branches:
- '*'
pull_request:
branches:
- '*'
# schedule:
# - cron: "0 0 * * */3"
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
inputs:
logLevel:
description: 'Log level'
required: true
default: 'warning'
tags:
description: 'Test scenario tags'
env:
TZ: Asia/Shanghai
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
buildx:
runs-on: ubuntu-22.04
steps:
-
name: Checkout
uses: actions/checkout@v4
with:
submodules: true
-
name: Get current date
id: date
run: echo "::set-output name=today::$(date +'%Y%m%d')"
-
name: Assign release version
run: |
cat Interfaces/VideoSubFinderWXW/MyResource.h| grep VSF_VERSION | sed -E 's/.+VSF_VERSION.+"(.+)"/release_version=\1/g' >> $GITHUB_ENV
-
name: Build cpu-static
run: bash ./Build/Docker/cpu_static/build.sh
-
name: Test
run: bash ./Build/Docker/cpu_static/test.sh
-
name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: videosubfinder-cli-cpu-linux-x64.tar.gz
path: |
./Build/Docker/cpu_static/out/videosubfinder-cli-cpu-static-linux-x64.tar.gz
./Build/Docker/cpu_static/out/videosubfinder-cli-cpu-static-upx-linux-x64.tar.gz
-
name: Release draft
uses: softprops/action-gh-release@v1
with:
draft: true
name: "${{ env.release_version }}"
tag_name: "${{ env.release_version }}-ci"
files: |
./Build/Docker/cpu_static/out/videosubfinder-cli-cpu-static-linux-x64.tar.gz
./Build/Docker/cpu_static/out/videosubfinder-cli-cpu-static-upx-linux-x64.tar.gz
body: "[Github Action](https://github.com/${{github.repository}}/actions/runs/${{github.run_id}})"