Skip to content

Commit dde300d

Browse files
authored
some good practices on workflows
1 parent 8bc6f0b commit dde300d

2 files changed

Lines changed: 44 additions & 45 deletions

File tree

.github/workflows/build-linux.yml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
name: Linux
2+
3+
on:
4+
push:
5+
branches: [ "main" ]
6+
pull_request:
7+
branches: [ "main" ]
8+
9+
permissions:
10+
contents: read
11+
12+
env:
13+
TARGET: acftool
14+
15+
jobs:
16+
build:
17+
name: Build Linux artifact
18+
runs-on: ubuntu-24.04
19+
timeout-minutes: 15
20+
21+
steps:
22+
- name: Checkout repository
23+
uses: actions/checkout@v4
24+
with:
25+
fetch-depth: 1
26+
27+
- name: Install toolchains
28+
run: |
29+
set -euo pipefail
30+
sudo apt update
31+
sudo apt install -y --no-install-recommends \
32+
build-essential
33+
34+
- name: Build Linux binary
35+
run: |
36+
set -euo pipefail
37+
make
38+
39+
- name: Upload Linux artifact
40+
uses: actions/upload-artifact@v4
41+
with:
42+
name: ${{ env.TARGET }}-linux
43+
path: ${{ env.TARGET }}
44+
if-no-files-found: error

.github/workflows/c-cpp.yml

Lines changed: 0 additions & 45 deletions
This file was deleted.

0 commit comments

Comments
 (0)