Skip to content

Commit 43590b6

Browse files
authored
Merge pull request #52 from dotnet-campus/t/lindexi/MediaConverter
准备添加多媒体处理模块
2 parents 864511a + 41ca24b commit 43590b6

97 files changed

Lines changed: 4377 additions & 1 deletion

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: MediaConverters
2+
3+
on: [push]
4+
5+
jobs:
6+
BuildOnWindows:
7+
8+
runs-on: windows-latest
9+
10+
steps:
11+
- uses: actions/checkout@v1
12+
13+
- name: Build with dotnet
14+
run: dotnet build --configuration Release src\MediaConverters\MediaConverters.sln
15+
16+
- name: Test
17+
run: dotnet test --configuration Release --no-build src\MediaConverters\MediaConverters.Tests\MediaConverters.Tests.csproj
18+
19+
BuildOnLinux:
20+
21+
runs-on: ubuntu-latest
22+
23+
steps:
24+
- uses: actions/checkout@v1
25+
- name: Setup dotnet
26+
uses: actions/setup-dotnet@v4
27+
with:
28+
dotnet-version: |
29+
9.0.x
30+
31+
- name: Build with dotnet
32+
run: dotnet build --configuration Release src/MediaConverters/MediaConverters.sln
33+
34+
- name: Test
35+
run: dotnet test --configuration Release --no-build src/MediaConverters/MediaConverters.Tests/MediaConverters.Tests.csproj
Lines changed: 137 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,137 @@
1+
name: Publish MediaConverters NuGet
2+
3+
on:
4+
push:
5+
tags:
6+
- '*'
7+
8+
jobs:
9+
PackOnWindows:
10+
11+
runs-on: windows-latest
12+
13+
steps:
14+
- uses: actions/checkout@v4
15+
16+
- name: Install dotnet tool
17+
run: dotnet tool install -g dotnetCampus.TagToVersion
18+
19+
- name: Set tag to version
20+
run: dotnet TagToVersion -t ${{ github.ref }}
21+
22+
- name: Build with dotnet
23+
run: dotnet build --configuration Release src\MediaConverters\MediaConverters.sln
24+
25+
- name: Pack MediaConverters.Tool.ContextNuGet
26+
run: dotnet pack --no-build true --configuration Release src\MediaConverters\MediaConverters.Tool.ContextNuGet\MediaConverters.Tool.ContextNuGet.csproj
27+
28+
- name: Publish and Pack win-x86
29+
run: |
30+
dotnet publish -c Release -r win-x86 src\MediaConverters\MediaConverters.Tool\MediaConverters.Tool.csproj
31+
dotnet pack --configuration Release /p:RuntimeIdentifier=win-x86 src\MediaConverters\MediaConverters.Tool.RuntimeNuGet\MediaConverters.Tool.RuntimeNuGet.csproj
32+
33+
- name: Publish and Pack win-x64
34+
run: |
35+
dotnet publish -c Release -r win-x64 src\MediaConverters\MediaConverters.Tool\MediaConverters.Tool.csproj
36+
dotnet pack --configuration Release /p:RuntimeIdentifier=win-x64 src\MediaConverters\MediaConverters.Tool.RuntimeNuGet\MediaConverters.Tool.RuntimeNuGet.csproj
37+
38+
- name: Push generated package to NuGet
39+
run: |
40+
dotnet nuget push .\bin\Release\*.nupkg -s https://api.nuget.org/v3/index.json -k ${{ secrets.NugetKey }}
41+
dotnet nuget push .\bin\Release\*.nupkg -s https://nuget.pkg.github.com/${{ github.repository_owner }} --api-key ${{ secrets.GITHUB_TOKEN }} --timeout 3000
42+
43+
PackOnWindowsArm64:
44+
45+
runs-on: windows-11-arm
46+
47+
steps:
48+
- uses: actions/checkout@v4
49+
50+
- name: Install dotnet tool
51+
run: dotnet tool install -g dotnetCampus.TagToVersion
52+
53+
- name: Set tag to version
54+
run: dotnet TagToVersion -t ${{ github.ref }}
55+
56+
- name: Build with dotnet
57+
run: dotnet build --configuration Release src\MediaConverters\MediaConverters.sln
58+
59+
- name: Publish and Pack win-arm64
60+
run: |
61+
dotnet publish -c Release -r win-arm64 src\MediaConverters\MediaConverters.Tool\MediaConverters.Tool.csproj
62+
dotnet pack --configuration Release /p:RuntimeIdentifier=win-arm64 src\MediaConverters\MediaConverters.Tool.RuntimeNuGet\MediaConverters.Tool.RuntimeNuGet.csproj
63+
64+
- name: Push generated package to NuGet
65+
run: |
66+
dotnet nuget push .\bin\Release\*.nupkg -s https://api.nuget.org/v3/index.json -k ${{ secrets.NugetKey }}
67+
dotnet nuget push .\bin\Release\*.nupkg -s https://nuget.pkg.github.com/${{ github.repository_owner }} --api-key ${{ secrets.GITHUB_TOKEN }} --timeout 3000
68+
69+
PackOnLinuxX64:
70+
71+
runs-on: ubuntu-latest
72+
73+
steps:
74+
- uses: actions/checkout@v4
75+
76+
- name: Install dotnet tool
77+
run: dotnet tool install -g dotnetCampus.TagToVersion
78+
79+
- name: Set tag to version
80+
run: dotnet TagToVersion -t ${{ github.ref }}
81+
82+
- name: Setup .NET
83+
uses: actions/setup-dotnet@v1
84+
with:
85+
dotnet-version: |
86+
3.1.x
87+
5.0.x
88+
6.0.x
89+
9.0.x
90+
91+
- name: Build with dotnet
92+
run: dotnet build --configuration Release src/MediaConverters/MediaConverters.sln
93+
94+
- name: Publish and Pack linux-x64
95+
run: |
96+
dotnet publish -c Release -r linux-x64 src/MediaConverters/MediaConverters.Tool/MediaConverters.Tool.csproj
97+
dotnet pack --configuration Release /p:RuntimeIdentifier=linux-x64 src/MediaConverters/MediaConverters.Tool.RuntimeNuGet/MediaConverters.Tool.RuntimeNuGet.csproj
98+
99+
- name: Push generated package to NuGet
100+
run: |
101+
dotnet nuget push ./bin/Release/*.nupkg -s https://api.nuget.org/v3/index.json -k ${{ secrets.NugetKey }}
102+
dotnet nuget push ./bin/Release/*.nupkg -s https://nuget.pkg.github.com/${{ github.repository_owner }} --api-key ${{ secrets.GITHUB_TOKEN }} --timeout 3000
103+
104+
PackOnLinuxArm64:
105+
106+
runs-on: ubuntu-24.04-arm
107+
108+
steps:
109+
- uses: actions/checkout@v4
110+
111+
- name: Install dotnet tool
112+
run: dotnet tool install -g dotnetCampus.TagToVersion
113+
114+
- name: Set tag to version
115+
run: dotnet TagToVersion -t ${{ github.ref }}
116+
117+
- name: Setup .NET
118+
uses: actions/setup-dotnet@v1
119+
with:
120+
dotnet-version: |
121+
3.1.x
122+
5.0.x
123+
6.0.x
124+
9.0.x
125+
126+
- name: Build with dotnet
127+
run: dotnet build --configuration Release src/MediaConverters/MediaConverters.sln
128+
129+
- name: Publish and Pack linux-arm64
130+
run: |
131+
dotnet publish -c Release -r linux-arm64 src/MediaConverters/MediaConverters.Tool/MediaConverters.Tool.csproj
132+
dotnet pack --configuration Release /p:RuntimeIdentifier=linux-arm64 src/MediaConverters/MediaConverters.Tool.RuntimeNuGet/MediaConverters.Tool.RuntimeNuGet.csproj
133+
134+
- name: Push generated package to NuGet
135+
run: |
136+
dotnet nuget push ./bin/Release/*.nupkg -s https://api.nuget.org/v3/index.json -k ${{ secrets.NugetKey }}
137+
dotnet nuget push ./bin/Release/*.nupkg -s https://nuget.pkg.github.com/${{ github.repository_owner }} --api-key ${{ secrets.GITHUB_TOKEN }} --timeout 3000

Directory.Build.props

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
<Description>The dotnet tools to assist in editing or reading the Office document files</Description>
1212

1313
<RepositoryType>git</RepositoryType>
14-
<Copyright>Copyright © 2020-$([System.DateTime]::Now.ToString(`yyyy`)) dotnet campus, All Rights Reserved.</Copyright>
14+
<Copyright>Copyright © 2020-$([System.DateTime]::Now.ToString(`yyyy`)) dotnet campus, All Rights Reserved.</Copyright>
15+
<PackageLicenseExpression>MIT</PackageLicenseExpression>
1516
</PropertyGroup>
1617
</Project>

0 commit comments

Comments
 (0)