Fix: expectations of .nuspec
Some checks failed
release-nuget-package / Release NuGet Package (push) Failing after 28s

This commit is contained in:
2026-02-13 19:52:28 +01:00
parent a8f46089c4
commit 81fc40cca9
3 changed files with 8 additions and 7 deletions

View File

@@ -9,8 +9,7 @@
<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="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'" Command="bash $(ProjectDir)release.sh $(TargetFramework) $([System.String]::Copy('$(MSBuildProjectName)').Replace('.Package',''))" />
<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" />
<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' OR '$(Configuration)' == 'PublishNuget')" Command="bash $(ProjectDir)release.sh $(TargetFramework) $([System.String]::Copy('$(MSBuildProjectName)').Replace('.Package','')) '$(Configuration)'" />
</Target>
</Project>

View File

@@ -17,7 +17,7 @@
</packageTypes>
</metadata>
<files>
<file src="./bin\Release\$targetframework$\$ProjectName$.dll" target="lib\$targetframework$" />
<file src="./bin\Release\$targetframework$\$ProjectName$.pdb" target="lib\$targetframework$" />
<file src="./bin\$configuration$\$targetframework$\$ProjectName$.dll" target="lib\$targetframework$" />
<file src="./bin\$configuration$\$targetframework$\$ProjectName$.pdb" target="lib\$targetframework$" />
</files>
</package>

View File

@@ -1,12 +1,14 @@
#!/bin/bash
TargetFramework=$1
ProjectName=$2
Configuration=$3
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 -eq 'PublishNuget' ]; then
echo "Skipping copy to Oqtane.Server/Packages"
else
echo "Copy to Oqtane.Server/Packages"
cp -f *.nupkg ../../oqtane.framework/Oqtane.Server/Packages/
fi