mirror of
https://github.com/nsnail/ns-ext.git
synced 2025-04-18 23:22:51 +08:00
..
This commit is contained in:
parent
32f5f27cd9
commit
b6279bb0bb
24
script/build-and-push.ps1
Normal file
24
script/build-and-push.ps1
Normal file
@ -0,0 +1,24 @@
|
||||
# ¶¨Òå²ÎÊý
|
||||
Param(
|
||||
# Nuget APIKey
|
||||
[string] $apikey
|
||||
)
|
||||
|
||||
if ($apikey -eq $null -or $apikey -eq "")
|
||||
{
|
||||
Write-Error "±ØÐëÖ¸¶¨apiKey";
|
||||
return;
|
||||
}
|
||||
|
||||
rm -r ../build/nupkgs/
|
||||
dotnet build -c Release ../src/NSExt.sln
|
||||
$files = Get-ChildItem -Path ../build/nupkgs/ -Filter *.nupkg
|
||||
foreach($file in $files)
|
||||
{
|
||||
dotnet nuget push $file.fullName --skip-duplicate --api-key $apikey --source https://api.nuget.org/v3/index.json
|
||||
}
|
||||
$files = Get-ChildItem -Path ../build/nupkgs/ -Filter *.snupkg
|
||||
foreach($file in $files)
|
||||
{
|
||||
dotnet nuget push $file.fullName --skip-duplicate --api-key $apikey --source https://api.nuget.org/v3/index.json
|
||||
}
|
@ -6,11 +6,11 @@
|
||||
<RepositoryUrl>https://github.com/nsnail/ns-ext.git</RepositoryUrl>
|
||||
<PublishRepositoryUrl>true</PublishRepositoryUrl>
|
||||
<EmbedUntrackedSource>true</EmbedUntrackedSource>
|
||||
<DebugSymbols>True</DebugSymbols>
|
||||
<DebugType>Embedded</DebugType>
|
||||
<EmbedAllSources>true</EmbedAllSources>
|
||||
<RepositoryType>Git</RepositoryType>
|
||||
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
|
||||
<IncludeSymbols>true</IncludeSymbols>
|
||||
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
|
||||
<PackageLicenseExpression>MIT</PackageLicenseExpression>
|
||||
<PackageProjectUrl>https://github.com/nsnail/ns-ext.git</PackageProjectUrl>
|
||||
<PackageOutputPath>../../build/nupkgs</PackageOutputPath>
|
||||
|
@ -3,7 +3,7 @@
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>net6.0;net7.0</TargetFrameworks>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<VersionPrefix>1.0.0</VersionPrefix>
|
||||
<VersionPrefix>1.0.2</VersionPrefix>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
Loading…
x
Reference in New Issue
Block a user