Skip to content

Commit 0e9533f

Browse files
authored
Create build.yml
1 parent 4e9d1a2 commit 0e9533f

File tree

1 file changed

+59
-0
lines changed

1 file changed

+59
-0
lines changed

.github/workflows/build.yml

+59
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
name: Build and Package
2+
3+
on:
4+
push:
5+
branches: [ "main" ]
6+
pull_request:
7+
branches: [ "main" ]
8+
workflow_dispatch:
9+
10+
jobs:
11+
build:
12+
name: Build Bootstrap
13+
runs-on: macos-latest
14+
15+
steps:
16+
- name: Checkout
17+
uses: actions/checkout@v3
18+
with:
19+
submodules: true
20+
21+
- name: Install Theos
22+
run: bash -c "$(curl -fsSL https://raw.githubusercontent.com/roothide/theos/master/bin/install-theos)"
23+
24+
- name: Setup Environment
25+
run: echo "THEOS=~/theos" >> $GITHUB_ENV
26+
27+
- name: Make Bootstrap Package
28+
run: make package
29+
30+
- name: Upload Artifact
31+
uses: actions/upload-artifact@v3
32+
with:
33+
name: Bootstrap.tipa
34+
path: ./packages/Bootstrap.tipa
35+
update-release:
36+
name: Release .tipa
37+
runs-on: ubuntu-latest
38+
needs: build
39+
40+
steps:
41+
- name: Delete old release
42+
uses: dev-drprasad/[email protected]
43+
with:
44+
delete_release: true
45+
tag_name: release
46+
env:
47+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
48+
- name: Get artifacts
49+
uses: actions/download-artifact@v3
50+
with:
51+
name: Bootstrap.tipa
52+
- name: Create new release
53+
uses: ncipollo/release-action@v1
54+
with:
55+
name: Rolling Release
56+
body: These are automatically updated builds of the latest commit.
57+
artifacts: "Bootstrap.tipa"
58+
tag: release
59+
token: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)