-
Notifications
You must be signed in to change notification settings - Fork 75
85 lines (75 loc) · 2.08 KB
/
build.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
73
74
75
76
77
78
79
80
81
82
83
84
85
name: Build
on:
push:
branches:
- main
paths:
- ".github/workflows/**"
- "script/build.*"
- "src/ffi.ts"
- "webview/**"
- ".gitmodules"
- "deno.json"
jobs:
build:
name: ${{ matrix.kind }} ${{ matrix.os }}
runs-on: ${{ matrix.os }}
timeout-minutes: 60
strategy:
matrix:
os:
[
macos-latest,
macos-13,
windows-latest,
ubuntu-latest,
ubuntu-24.04-arm,
]
steps:
- name: Clone repository
uses: actions/checkout@v3
with:
submodules: true
- name: Install deno
uses: denoland/setup-deno@v1
with:
deno-version: v2.x
- name: install webkit2gtk (Linux)
if: startsWith(matrix.os, 'ubuntu')
run: |
sudo apt-get update
sudo apt-get install -y webkitgtk-6.0 libwebkitgtk-6.0-dev cmake ninja-build clang pkg-config libgtk-4-dev
- name: Install ninja (macOS)
if: startsWith(matrix.os, 'macos')
run: |
brew install ninja
brew install llvm
echo "WEBVIEW_CLANG_FORMAT_EXE=$(brew --prefix llvm)/bin/clang-format" >> $GITHUB_ENV
- name: Install ninja (Windows)
if: matrix.os == 'windows-latest'
run: |
choco install ninja
- name: Build dynamic library
run: deno task build
- name: Upload Artifacts
uses: actions/upload-artifact@v3
with:
name: build
path: |
build/*.dll
build/*.dylib
build/*.so
# - name: Release Plugin
# uses: softprops/action-gh-release@master
# env:
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# with:
# tag_name: "webview_deno release"
# draft: true
# files: |
# build/libwebview.x86_64.dylib
# build/libwebview.aarch64.dylib
# build/libwebview.x86_64.so
# build/libwebview.aarch64.so
# build/webview.dll
# build/Webview2Loader.dll