Skip to content

Commit 11a8f94

Browse files
committed
调整目录结构,新增nuget打包上传脚本
1 parent cb13091 commit 11a8f94

File tree

14 files changed

+34
-5
lines changed

14 files changed

+34
-5
lines changed

.github/workflows/openharmony-build.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,3 +34,20 @@ jobs:
3434
run: |
3535
chmod +x ./build-openharmony-arm64.sh
3636
./build-openharmony-arm64.sh
37+
38+
- name: pack nuget
39+
working-directory: ${{ github.workspace }}/package
40+
nuget pack ./OpenHarmony.NET.Runtime.nuspec -OutputDirectory ../output -Version 0.0.0-alpha.${{github.run_number}}
41+
42+
publish-to-nuget:
43+
needs: build
44+
runs-on: ubuntu-latest
45+
if: github.event_name == 'push'
46+
steps:
47+
- uses: actions/download-artifact@v4
48+
with:
49+
name: packages
50+
path: output
51+
- name: Push to NuGet
52+
run: |
53+
dotnet nuget push **/*.nupkg --api-key ${{ secrets.NUGET_API_KEY }} --source https://api.nuget.org/v3/index.json --skip-duplicate
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
<?xml version="1.0"?>
2+
<package xmlns="http://schemas.microsoft.com/packaging/2013/05/nuspec.xsd">
3+
<metadata>
4+
<id>OpenHarmony.NET.Runtime</id>
5+
<version>1.0.0</version>
6+
<authors>OpenHarmony.NET</authors>
7+
<description>.NET AOT Runtime for OpenHarmony</description>
8+
</metadata>
9+
<files>
10+
<file src="build\runtime.targets" target="build\runtime.targets" />
11+
</files>
12+
</package>

0 commit comments

Comments
 (0)