-
Notifications
You must be signed in to change notification settings - Fork 30
106 lines (92 loc) · 2.57 KB
/
main.yml
File metadata and controls
106 lines (92 loc) · 2.57 KB
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
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
name: CI Workflow
on:
push:
branches: [ "main" ]
paths-ignore:
- 'readme'
- '.gitignore'
- 'README.md'
pull_request:
branches: [ "main" ]
paths-ignore:
- 'readme'
- '.gitignore'
- 'README.md'
jobs:
i386:
runs-on: ubuntu-latest
name: i386
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install packages
uses: awalsh128/cache-apt-pkgs-action@latest
with:
packages: xorriso nasm mtools
version: 1.0
- name: Setup xmake
uses: wenxuanjun/github-action-setup-xmake@master
with:
xmake-version: latest
actions-cache-folder: '.xmake-cache'
actions-cache-key: ${{ matrix.os }}
build-cache: true
build-cache-key: ${{ matrix.os }}
package-cache: true
package-cache-key: ${{ matrix.os }}
- name: Build CoolPotOS-i386
run: |
xmake f -y --arch=i686
xmake build iso
- name: Upload CoolPotOS-i386 ISO
uses: actions/upload-artifact@v4
with:
name: CoolPotOS-i386 (ISO)
path: build/CoolPotOS.iso
compression-level: 9
x86_64:
runs-on: ubuntu-latest
name: x86_64
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install OS image builder
uses: baptiste0928/cargo-install@v3
with:
crate: oib
- name: Install cbindgen
uses: baptiste0928/cargo-install@v3
with:
crate: cbindgen
- name: Install packages
uses: awalsh128/cache-apt-pkgs-action@latest
with:
packages: xorriso clang mtools lld
version: 1.0
- name: Setup xmake
uses: wenxuanjun/github-action-setup-xmake@master
with:
xmake-version: latest
actions-cache-folder: '.xmake-cache'
build-cache: true
package-cache: true
- name: Build CoolPotOS-x86_64
run: |
xmake f -y --arch=x86_64
xmake build e1000
xmake build extfs
xmake build nvme
xmake build iso
xmake build img
- name: Upload CoolPotOS-x86_64 ISO
uses: actions/upload-artifact@v4
with:
name: CoolPotOS-x86_64 (ISO)
path: build/CoolPotOS.iso
compression-level: 9
- name: Upload CoolPotOS-x86_64 IMG
uses: actions/upload-artifact@v4
with:
name: CoolPotOS-x86_64 (IMG)
path: build/CoolPotOS.img
compression-level: 9