-
Notifications
You must be signed in to change notification settings - Fork 72
112 lines (88 loc) · 3.17 KB
/
cli.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
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
name: Build CLI
on:
push:
tags:
- 'cli-*'
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/[email protected]
- name: setup zip
uses: montudor/[email protected]
- name: setup dotnet
uses: actions/[email protected]
with:
dotnet-version: 8.0.x
- name: publish dotnet
run: |
cd cli/Squidex.CLI/Squidex.CLI
dotnet publish -c Release
- name: publish win-x64
run: |
cd cli/Squidex.CLI/Squidex.CLI
dotnet publish -r win-x64 --self-contained -c Release /p:PublishSingleFile=true
- name: publish win-x86
run: |
cd cli/Squidex.CLI/Squidex.CLI
dotnet publish -r win-x86 --self-contained -c Release /p:PublishSingleFile=true
- name: publish linux-x64
run: |
cd cli/Squidex.CLI/Squidex.CLI
dotnet publish -r linux-x64 --self-contained -c Release /p:PublishSingleFile=true
- name: publish osx-x64
run: |
cd cli/Squidex.CLI/Squidex.CLI
dotnet publish -r osx-x64 --self-contained -c Release /p:PublishSingleFile=true
- name: publish osx-arm64
run: |
cd cli/Squidex.CLI/Squidex.CLI
dotnet publish -r osx-arm64 --self-contained -c Release /p:PublishSingleFile=true
- name: pack dotnet tool
run: |
cd cli/Squidex.CLI/Squidex.CLI
dotnet pack -p:PackDotnetTool=1 -c Release
- name: push dotnet tool to nuget.org
run: |
cd cli/Squidex.CLI/Squidex.CLI/bin/Release
dotnet nuget push **/*.nupkg --source 'https://api.nuget.org/v3/index.json' --skip-duplicate -k ${{ secrets.nuget }}
- name: pack core
run: |
cd cli/Squidex.CLI/Squidex.CLI.Core
dotnet pack -c Release
- name: push core to nuget.org
run: |
cd cli/Squidex.CLI/Squidex.CLI.Core/bin/Release
dotnet nuget push **/*.nupkg --source 'https://api.nuget.org/v3/index.json' --skip-duplicate -k ${{ secrets.nuget }}
- name: create dir
run: |
mkdir cli/Squidex.CLI/Squidex.CLI/bin/Release/out
- name: archive dotnet
run: |
cd cli/Squidex.CLI/Squidex.CLI/bin/Release/net8.0/publish/
zip -r '../../out/dotnet.zip' *
- name: archive win-x64
run: |
cd cli/Squidex.CLI/Squidex.CLI/bin/Release/net8.0/win-x64/publish/
zip -r '../../../out/win-x64.zip' *
- name: archive win-x86
run: |
cd cli/Squidex.CLI/Squidex.CLI/bin/Release/net8.0/win-x86/publish/
zip -r '../../../out/win-x86.zip' *
- name: archive linux-x64
run: |
cd cli/Squidex.CLI/Squidex.CLI/bin/Release/net8.0/linux-x64/publish/
zip -r '../../..//out/linux-x64.zip' *
- name: archive osx-x64
run: |
cd cli/Squidex.CLI/Squidex.CLI/bin/Release/net8.0/osx-x64/publish/
zip -r '../../../out/osx-x64.zip' *
- name: archive osx-arm64
run: |
cd cli/Squidex.CLI/Squidex.CLI/bin/Release/net8.0/osx-arm64/publish/
zip -r '../../../out/osx-arm64.zip' *
- name: release
uses: fnkr/github-action-ghr@v1
env:
GITHUB_TOKEN: ${{ secrets.project }}
GHR_PATH: 'cli/Squidex.CLI/Squidex.CLI/bin/Release/out/'