Skip to content

Commit 5020f5c

Browse files
authored
Update appveyor.yml
1 parent 5db185d commit 5020f5c

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

appveyor.yml

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ branches:
44
- master
55
- /dev.*/
66
- /release.*/
7+
- /v.*/
78

89
image: Visual Studio 2017
910

@@ -42,11 +43,13 @@ environment:
4243
secure: E3bCMe4LtDdAhHSYRcLp0N6DixJe1m8TNxhYeJW/GnqM3WXdRqsgkHSbwootPjJQtOQJrps4twmzTVzofLSVgPgbzU8PxU0AkJV7zwkyVOE=
4344

4445
init:
45-
- git config --global core.autocrlf true
46-
- git config --global credential.helper store
47-
- ps: Add-Content "$env:USERPROFILE\.git-credentials" "https://$($env:GitHubToken):[email protected]`n"
48-
- git config --global user.email "%GitHubUserEmail%"
49-
- git config --global user.name "%GitHubUserName%"
46+
- git config --global core.autocrlf true
47+
- git config --global credential.helper store
48+
- ps: Add-Content "$env:USERPROFILE\.git-credentials" "https://$($env:GitHubToken):[email protected]`n"
49+
- git config --global user.email "%GitHubUserEmail%"
50+
- git config --global user.name "%GitHubUserName%"
51+
- ps: "$headers = if($env:APPVEYOR_PULL_REQUEST_NUMBER){\n @{\n \"Authorization\" = \"Basic $env:GitRestAuth\"\n \"Content-type\" = \"application/json\"\n}\n\n$pr = Invoke-RestMethod -Uri \"https://api.github.com/repos/$env:APPVEYOR_REPO_NAME/pulls/$env:APPVEYOR_PULL_REQUEST_NUMBER\" -Headers $headers -Method GET\n\nif($pr.user.login -eq \"nfbot\" -and $pr.body -match \"*[version update]*\")\n{\n # commit was from nfbot AND it's taged as a [version update]\n # OK to skip AppVeyor build \n \"Version update only. Skipping build.\" | Write-Host -BackgroundColor White -ForegroundColor Blue\n Exit-AppveyorBuild\n} }\n"
52+
- ps: "if($env:APPVEYOR_PULL_REQUEST_NUMBER -eq \"\")\n{\n \n if($env:APPVEYOR_REPO_COMMIT_AUTHOR -eq \"nfbot\" -and $env:APPVEYOR_REPO_COMMIT_MESSAGE_EXTENDED -like \"*[version update]*\")\n {\n # commit was from nfbot AND it's taged as a [version update]\n # OK to skip AppVeyor build \n \"Version update only. Skipping build.\" | Write-Host -BackgroundColor White -ForegroundColor Blue\n Exit-AppveyorBuild\n }\n}"
5053

5154
install:
5255
- set PATH=C:\Ruby%RUBY_VERSION%\bin;%PATH%
@@ -101,6 +104,7 @@ for:
101104
branches:
102105
only:
103106
- master
107+
- /v.*/
104108

105109
deploy:
106110
- provider: NuGet

0 commit comments

Comments
 (0)