-
-
Notifications
You must be signed in to change notification settings - Fork 172
/
appveyor.yml
50 lines (42 loc) · 2.35 KB
/
appveyor.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
image: Visual Studio 2017
install:
- ps: (new-object Net.WebClient).DownloadString("https://raw.github.com/madskristensen/ExtensionScripts/master/AppVeyor/vsix.ps1") | iex
- ps: $urlCurrent = "https://download.visualstudio.microsoft.com/download/pr/adeab8b1-1c44-41b2-b12a-156442f307e9/65ebf805366410c63edeb06e53959383/dotnet-sdk-3.1.201-win-x64.zip"
- ps: $env:DOTNET_INSTALL_DIR = "$pwd\.dotnetsdk"
- ps: mkdir $env:DOTNET_INSTALL_DIR -Force | Out-Null
- ps: $tempFileCurrent = [System.IO.Path]::GetTempFileName()
- ps: (New-Object System.Net.WebClient).DownloadFile($urlCurrent, $tempFileCurrent)
- ps: Add-Type -AssemblyName System.IO.Compression.FileSystem; [System.IO.Compression.ZipFile]::ExtractToDirectory($tempFileCurrent, $env:DOTNET_INSTALL_DIR)
- ps: $env:Path = "$env:DOTNET_INSTALL_DIR;$env:Path"
before_build:
- ps: Vsix-IncrementVsixVersion | Vsix-UpdateBuildVersion
- ps: Vsix-TokenReplacement src\BundlerMinifier.Core\Constants.cs 'VERSION = "([0-9\\.]+)"' 'VERSION = "{version}"'
build_script:
- dotnet restore BundlerMinifier.sln
- nuget restore .\src\BundlerMinifierVSIX -Verbosity quiet -PackagesDirectory .\Packages
- msbuild .\src\BundlerMinifierConsole\BundlerMinifierConsole.csproj /p:configuration=Release /v:m
- msbuild .\src\BundlerMinifierVSIX\BundlerMinifierVSIX.csproj /p:configuration=Release /p:DeployExtension=false /p:ZipPackageCompressionLevel=normal /v:m
- msbuild .\src\BundlerMinifierTest\BundlerMinifierTest.csproj /p:configuration=Release /v:m
- ps: dotnet pack src\BundlerMinifier\ -c Release "/p:Version=${env:APPVEYOR_BUILD_VERSION}"
- ps: dotnet pack src\BundlerMinifier.Core\ -c Release "/p:Version=${env:APPVEYOR_BUILD_VERSION}"
- ps: dotnet pack src\BundlerMinifier.TagHelpers\ -c Release "/p:Version=${env:APPVEYOR_BUILD_VERSION}"
after_test:
- ps: Vsix-PushArtifacts | Vsix-PublishToGallery .\src\BundlerMinifierVsix\**\*.vsix
artifacts:
- path: src\**\*.nupkg
name: NuGet package
before_deploy:
- ps: Vsix-CreateChocolatyPackage -packageId bundlerminifier
deploy:
- provider: NuGet
artifact: /NuGet/
api_key:
secure: oy2inuap4zo4iqrna3galf3x3gtz42vuvii2pyetfbfwkq
on:
branch: master
appveyor_repo_commit_message_extended: /\[release\]/
- provider: Environment
name: Chocolatey
on:
branch: master
appveyor_repo_commit_message_extended: /\[release\]/