Skip to content

Commit bd80e87

Browse files
committed
up add build
1 parent ecc3a7d commit bd80e87

File tree

4 files changed

+97
-8
lines changed

4 files changed

+97
-8
lines changed

.github/workflows/webplugin-build.yml

+73
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
name: 浏览器支持构建
2+
3+
on:
4+
push:
5+
# Sequence of patterns matched against refs/heads
6+
branches:
7+
- 'releases/**'
8+
# Sequence of patterns matched against refs/tags
9+
tags:
10+
- '*'
11+
12+
jobs:
13+
build-plugins:
14+
runs-on: ubuntu-latest
15+
steps:
16+
- name: Checkout code
17+
uses: actions/checkout@v3
18+
with:
19+
submodules: 'true'
20+
token: ${{ secrets.KEY1 }}
21+
22+
- name: 设置.NET Core
23+
uses: actions/setup-dotnet@v4
24+
with:
25+
dotnet-version: 8.0.404
26+
27+
# - name: 更新源码
28+
# working-directory: ./
29+
# run: |
30+
# chmod a+x ./build/update.sh
31+
# ./build/update.sh
32+
33+
- name: 构建 源码
34+
working-directory: ./
35+
run: |
36+
chmod a+x ./build/build-buildweb.sh
37+
./build/build-buildweb.sh
38+
39+
- name: 上传 colordesktop-webplugin-win-x64
40+
uses: actions/upload-artifact@v4
41+
with:
42+
name: "colordesktop-webplugin-win-x64"
43+
path: src/build_out/Debug/net8.0/webplugin-win-x64.zip
44+
45+
- name: 上传 colordesktop-webplugin-win-arm64
46+
uses: actions/upload-artifact@v4
47+
with:
48+
name: "colordesktop-webplugin-win-arm64"
49+
path: src/build_out/Debug/net8.0/webplugin-win-arm64.zip
50+
51+
- name: 上传 colordesktop-webplugin-linux-x64
52+
uses: actions/upload-artifact@v4
53+
with:
54+
name: "colordesktop-webplugin-linux-x64"
55+
path: src/build_out/Debug/net8.0/webplugin-linux-x64.zip
56+
57+
- name: 上传 colordesktop-webplugin-linux-arm64
58+
uses: actions/upload-artifact@v4
59+
with:
60+
name: "colordesktop-webplugin-linux-arm64"
61+
path: src/build_out/Debug/net8.0/webplugin-linux-arm64.zip
62+
63+
- name: 上传 colordesktop-webplugin-osx-x64
64+
uses: actions/upload-artifact@v4
65+
with:
66+
name: "colordesktop-webplugin-osx-x64"
67+
path: src/build_out/Debug/net8.0/webplugin-osx-x64.zip
68+
69+
- name: 上传 colordesktop-webplugin-osx-arm64
70+
uses: actions/upload-artifact@v4
71+
with:
72+
name: "colordesktop-webplugin-osx-arm64"
73+
path: src/build_out/Debug/net8.0/webplugin-osx-arm64.zip

build/build-buildweb.sh

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
#!/bin/bash
2+
3+
mkdir ./build_out
4+
5+
dotnet restore ./src/ColorDesktop.sln
6+
7+
cd ./src/Core/ColorDesktop.Web
8+
9+
dotnet msbuild -p:RuntimeIdentifier=win-x64
10+
dotnet msbuild -p:RuntimeIdentifier=win-arm64
11+
dotnet msbuild -p:RuntimeIdentifier=linux-x64
12+
dotnet msbuild -p:RuntimeIdentifier=linux-arm64
13+
dotnet msbuild -p:RuntimeIdentifier=osx-x64
14+
dotnet msbuild -p:RuntimeIdentifier=osx-arm64
15+
16+
cd ./src/build_out/Debug/net8.0/
17+
18+
zip -r webplugin-linux-arm64.zip WebPlugin/Debug/net8.0/linux-arm64
19+
zip -r webplugin-linux-x64.zip WebPlugin/Debug/net8.0/linux-x64
20+
zip -r webplugin-osx-arm64.zip WebPlugin/Debug/net8.0/osx-arm64
21+
zip -r webplugin-osx-x64.zip WebPlugin/Debug/net8.0/osx-x64
22+
zip -r webplugin-win-arm64.zip WebPlugin/Debug/net8.0/win-arm64
23+
zip -r webplugin-win-x64.zip WebPlugin/Debug/net8.0/win-x64

src/ColorDesktop.Api/ColorDesktop.Api.csproj

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
<Nullable>enable</Nullable>
77
<Platforms>AnyCPU</Platforms>
88
<Title>ColorDesktop Api</Title>
9-
<Version>4.0.1</Version>
9+
<Version>4.0.0</Version>
1010
<Authors>Coloryr</Authors>
1111
<Company>Coloryr</Company>
1212
<Description>ColorDesktop的API</Description>

src/Core/ColorDesktop.Web/build.sh

-7
This file was deleted.

0 commit comments

Comments
 (0)