File tree Expand file tree Collapse file tree 1 file changed +16
-2
lines changed Expand file tree Collapse file tree 1 file changed +16
-2
lines changed Original file line number Diff line number Diff line change 1
1
@ echo off
2
2
3
- for /f " usebackq tokens=3" %%i in (`findstr PHP_MAJOR_VERSION main\php_version.h`) do set BRANCH = %%i
4
- for /f " usebackq tokens=3" %%i in (`findstr PHP_MINOR_VERSION main\php_version.h`) do set BRANCH = %BRANCH% .%%i
3
+ if /i " %APPVEYOR% " equ " True" (
4
+ set BRANCH = %APPVEYOR_REPO_BRANCH:~4 ,3 %
5
+ ) else (
6
+ if " %GITHUB_BASE_REF% " equ " master" (
7
+ set IS_MASTER = " True"
8
+ )
9
+ if " %GITHUB_HEAD_REF% " equ " master" (
10
+ set IS_MASTER = " True"
11
+ )
12
+ if " %IS_MASTER% " equ " True" (
13
+ set BRANCH = " master"
14
+ ) else (
15
+ for /f " usebackq tokens=3" %%i in (`findstr PHP_MAJOR_VERSION main\php_version.h`) do set BRANCH = %%i
16
+ for /f " usebackq tokens=3" %%i in (`findstr PHP_MINOR_VERSION main\php_version.h`) do set BRANCH = %BRANCH% .%%i
17
+ )
18
+ )
You can’t perform that action at this time.
0 commit comments