Skip to content

Commit 7c17f1d

Browse files
committed
Align powershell command contents
1 parent cf9991c commit 7c17f1d

File tree

1 file changed

+25
-26
lines changed

1 file changed

+25
-26
lines changed

.appveyor.yml

Lines changed: 25 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -28,36 +28,35 @@ init:
2828
install:
2929
# php
3030
- ps: |
31-
# Check if installation is cached
32-
if (!(Test-Path c:\tools\php)) {
33-
appveyor-retry cinst --params '""/InstallDir:C:\tools\php""' --ignore-checksums -y php --version ((choco search php --exact --all-versions -r | select-string -pattern $env:php | sort { [version]($_ -split '\|' | select -last 1) } -Descending | Select-Object -first 1) -replace '[php|]','')
34-
Get-ChildItem -Path c:\tools\php
35-
cd c:\tools\php
36-
copy php.ini-production php.ini
37-
Add-Content php.ini "`n date.timezone=UTC"
38-
Add-Content php.ini "`n extension_dir=ext"
39-
Add-Content php.ini "`n memory_limit=1G"
40-
Add-Content php.ini "`n extension=php_openssl.dll"
41-
Add-Content php.ini "`n extension=php_mbstring.dll"
42-
Add-Content php.ini "`n extension=php_fileinfo.dll"
43-
Add-Content php.ini "`n extension=php_curl.dll"
44-
Add-Content php.ini "`n extension=php_xsl.dll"
45-
Add-Content php.ini "`n extension=php_soap.dll"
46-
}
31+
if (!(Test-Path c:\tools\php)) {
32+
appveyor-retry cinst --params '""/InstallDir:C:\tools\php""' --ignore-checksums -y php --version ((choco search php --exact --all-versions -r | select-string -pattern $env:php | sort { [version]($_ -split '\|' | select -last 1) } -Descending | Select-Object -first 1) -replace '[php|]','')
33+
Get-ChildItem -Path c:\tools\php
34+
cd c:\tools\php
35+
copy php.ini-production php.ini
36+
Add-Content php.ini "`n date.timezone=UTC"
37+
Add-Content php.ini "`n extension_dir=ext"
38+
Add-Content php.ini "`n memory_limit=1G"
39+
Add-Content php.ini "`n extension=php_openssl.dll"
40+
Add-Content php.ini "`n extension=php_mbstring.dll"
41+
Add-Content php.ini "`n extension=php_fileinfo.dll"
42+
Add-Content php.ini "`n extension=php_curl.dll"
43+
Add-Content php.ini "`n extension=php_xsl.dll"
44+
Add-Content php.ini "`n extension=php_soap.dll"
45+
}
4746
# composer
4847
- ps: |
49-
if (!(Test-Path C:\tools\composer)) {
50-
New-Item -path c:\tools -name composer -itemtype directory
51-
}
52-
if (!(Test-Path c:\tools\composer\composer.phar)) {
53-
appveyor-retry appveyor DownloadFile https://getcomposer.org/composer.phar -Filename C:\tools\composer\composer.phar
54-
Set-Content -path 'C:\tools\composer\composer.bat' -Value ('@php C:\tools\composer\composer.phar %*')
55-
}
48+
if (!(Test-Path C:\tools\composer)) {
49+
New-Item -path c:\tools -name composer -itemtype directory
50+
}
51+
if (!(Test-Path c:\tools\composer\composer.phar)) {
52+
appveyor-retry appveyor DownloadFile https://getcomposer.org/composer.phar -Filename C:\tools\composer\composer.phar
53+
Set-Content -path 'C:\tools\composer\composer.bat' -Value ('@php C:\tools\composer\composer.phar %*')
54+
}
5655
# saxonb
5756
- ps: |
58-
if (!(Test-Path C:\ProgramData\chocolatey\bin\SaxonHE\bin\Transform.exe)) {
59-
appveyor-retry cinst --ignore-checksums -y saxonhe
60-
}
57+
if (!(Test-Path C:\ProgramData\chocolatey\bin\SaxonHE\bin\Transform.exe)) {
58+
appveyor-retry cinst --ignore-checksums -y saxonhe
59+
}
6160
# install composer dependences
6261
- cd c:\projects\project
6362
- appveyor-retry composer self-update --no-progress --no-interaction

0 commit comments

Comments
 (0)