Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| a798ee544e | |||
| aece91aff0 | |||
| b1786eb578 | |||
| 79d7058e66 | |||
| 81fc40cca9 |
@@ -17,12 +17,12 @@ jobs:
|
|||||||
uses: actions/setup-dotnet@v4
|
uses: actions/setup-dotnet@v4
|
||||||
with:
|
with:
|
||||||
dotnet-version: "10.0.x"
|
dotnet-version: "10.0.x"
|
||||||
- name: "Get configured dotnet sources"
|
- name: "Configure nuget source"
|
||||||
run: dotnet nuget list sources
|
run: dotnet nuget add source --name DAV --username kocoder --password ${{ secrets.REGISTRY_TOKEN_KOCODER }} https://git.kocoder.xyz/api/packages/Diplomarbeit-Absolventenverein/nuget/index.json --store-password-in-clear-text
|
||||||
- name: "Build Interfaces Project"
|
- name: "Build Interfaces Project"
|
||||||
run: dotnet build -c PublishNuget ./Interfaces/Interfaces.csproj
|
run: dotnet build -c PublishNuget ./Interfaces/Interfaces.csproj
|
||||||
- name: "Release to Package Registry"
|
- name: "Release to Package Registry"
|
||||||
run: dotnet nuget push --source gitea --api-key ${{ secrets.REGISTRY_TOKEN_KOCODER }} ./Interfaces/Interfaces.*.nupkg
|
run: dotnet nuget push --source DAV --api-key ${{ secrets.REGISTRY_TOKEN_KOCODER }} ./Interfaces/Interfaces.*.nupkg
|
||||||
- name: "Create release"
|
- name: "Create release"
|
||||||
uses: akkuman/gitea-release-action@v1
|
uses: akkuman/gitea-release-action@v1
|
||||||
with:
|
with:
|
||||||
|
|||||||
@@ -9,8 +9,7 @@
|
|||||||
<Target Name="PostBuild" AfterTargets="PostBuildEvent">
|
<Target Name="PostBuild" AfterTargets="PostBuildEvent">
|
||||||
<Exec Condition="'$(OS)' == 'Windows_NT' And '$(Configuration)' == 'Debug'" Command="debug.cmd $(TargetFramework) $([System.String]::Copy('$(MSBuildProjectName)').Replace('.Package',''))" />
|
<Exec Condition="'$(OS)' == 'Windows_NT' And '$(Configuration)' == 'Debug'" Command="debug.cmd $(TargetFramework) $([System.String]::Copy('$(MSBuildProjectName)').Replace('.Package',''))" />
|
||||||
<Exec Condition="'$(OS)' != 'Windows_NT' And '$(Configuration)' == 'Debug'" Command="bash $(ProjectDir)debug.sh $(TargetFramework) $([System.String]::Copy('$(MSBuildProjectName)').Replace('.Package',''))" />
|
<Exec Condition="'$(OS)' != 'Windows_NT' And '$(Configuration)' == 'Debug'" Command="bash $(ProjectDir)debug.sh $(TargetFramework) $([System.String]::Copy('$(MSBuildProjectName)').Replace('.Package',''))" />
|
||||||
<Exec Condition="'$(OS)' == 'Windows_NT' And '$(Configuration)' == 'Release'" Command="release.cmd $(TargetFramework) $([System.String]::Copy('$(MSBuildProjectName)').Replace('.Package',''))" />
|
<Exec Condition="'$(OS)' == 'Windows_NT' And ('$(Configuration)' == 'Release' OR '$(Configuration)' == 'PublishNuget')" Command="release.cmd $(TargetFramework) $([System.String]::Copy('$(MSBuildProjectName)').Replace('.Package','')) '$(Configuration)'" />
|
||||||
<Exec Condition="'$(OS)' != 'Windows_NT' And '$(Configuration)' == 'Release'" Command="bash $(ProjectDir)release.sh $(TargetFramework) $([System.String]::Copy('$(MSBuildProjectName)').Replace('.Package',''))" />
|
<Exec Condition="'$(OS)' != 'Windows_NT' And ('$(Configuration)' == 'Release' OR '$(Configuration)' == 'PublishNuget')" Command="bash $(ProjectDir)release.sh $(TargetFramework) $([System.String]::Copy('$(MSBuildProjectName)').Replace('.Package','')) '$(Configuration)'" />
|
||||||
<Exec Condition="'$(OS)' != 'Windows_NT' And '$(Configuration)' == 'PublishNuget'" Command="bash $(ProjectDir)release.sh $(TargetFramework) $([System.String]::Copy('$(MSBuildProjectName)').Replace('.Package','')) skip-copy-to-oqtane.framework" />
|
|
||||||
</Target>
|
</Target>
|
||||||
</Project>
|
</Project>
|
||||||
|
|||||||
@@ -17,7 +17,7 @@
|
|||||||
</packageTypes>
|
</packageTypes>
|
||||||
</metadata>
|
</metadata>
|
||||||
<files>
|
<files>
|
||||||
<file src="./bin\Release\$targetframework$\$ProjectName$.dll" target="lib\$targetframework$" />
|
<file src="./bin\$configuration$\$targetframework$\$ProjectName$.dll" target="lib\$targetframework$" />
|
||||||
<file src="./bin\Release\$targetframework$\$ProjectName$.pdb" target="lib\$targetframework$" />
|
<file src="./bin\$configuration$\$targetframework$\$ProjectName$.pdb" target="lib\$targetframework$" />
|
||||||
</files>
|
</files>
|
||||||
</package>
|
</package>
|
||||||
@@ -1,12 +1,17 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
TargetFramework=$1
|
TargetFramework=$1
|
||||||
ProjectName=$2
|
ProjectName=$2
|
||||||
|
Configuration=$3
|
||||||
|
|
||||||
|
echo "ENV: ${TargetFramework} ${ProjectName} ${Configuration} RN: ${ gitea.ref_name } :NR ${REF_NAME}"
|
||||||
|
|
||||||
|
|
||||||
find . -name *.nupkg -delete
|
find . -name *.nupkg -delete
|
||||||
dotnet pack $ProjectName.nuspec "/p:targetframework=${TargetFramework};ProjectName=${ProjectName}"
|
dotnet pack $ProjectName.nuspec "/p:targetframework=${TargetFramework};ProjectName=${ProjectName};configuration=${Configuration}"
|
||||||
|
|
||||||
if [ "$#" -ne 3 ]; then
|
if [ $Configuration == 'PublishNuget' ]; then
|
||||||
echo "Skipping copy to Oqtane.Server/Packages"
|
echo "Skipping copy to Oqtane.Server/Packages"
|
||||||
else
|
else
|
||||||
|
echo "Copy to Oqtane.Server/Packages"
|
||||||
cp -f *.nupkg ../../oqtane.framework/Oqtane.Server/Packages/
|
cp -f *.nupkg ../../oqtane.framework/Oqtane.Server/Packages/
|
||||||
fi
|
fi
|
||||||
Reference in New Issue
Block a user