@@ -340,7 +340,8 @@ $composer_json = "$env:APPDATA\Composer\composer.json"
340340$composer_lock = " $env: APPDATA \Composer\composer.lock"
341341$current_profile = " $env: TEMP \setup-php.ps1"
342342$ProgressPreference = ' SilentlyContinue'
343- $nightly_version = ' 8.[0-9]'
343+ $jit_versions = ' 8.[0-9]'
344+ $nightly_versions = ' 8.[1-9]'
344345$cert_source = ' CurrentUser'
345346$enable_extensions = (' openssl' , ' curl' , ' mbstring' )
346347
@@ -399,14 +400,17 @@ if ($null -eq $installed -or -not("$($installed.Version).".StartsWith(($version
399400 Install-PSPackage VcRedist VcRedist- main\VcRedist\VcRedist " $github /aaronparker/VcRedist/archive/main.zip" > $null 2>&1
400401 }
401402 try {
402- if ($version -match $nightly_version ) {
403- Invoke-WebRequest - Uri $bintray / Get-PhpNightly.ps1 - OutFile $php_dir \Get-PhpNightly.ps1 > $null 2>&1
404- & $php_dir \Get-PhpNightly.ps1 - Architecture $arch - ThreadSafe $ts - Path $php_dir - Version $version > $null 2>&1
403+ if ($version -match $nightly_versions ) {
404+ Invoke-WebRequest - UseBasicParsing - Uri https: // github.com / shivammathur / php - builder - windows / releases / latest / download / Get-PhpNightly.ps1 - OutFile $php_dir \Get-PhpNightly.ps1 > $null 2>&1
405+ & $php_dir \Get-PhpNightly.ps1 - Architecture $arch - ThreadSafe $ts - Path $php_dir > $null 2>&1
405406 } else {
406407 Install-Php - Version $version - Architecture $arch - ThreadSafe $ts - InstallVC - Path $php_dir - TimeZone UTC - InitialPhpIni Production - Force > $null 2>&1
407408 }
408409 } catch { }
409410} else {
411+ if ($version -match $jit_versions ) {
412+ (' opcache.enable=1' , ' opcache.jit_buffer_size=256M' , ' opcache.jit=1235' ) | ForEach-Object { $p = $_.split (' =' ); Set-PhpIniKey - Key $p [0 ] - Value $p [1 ] - Path $php_dir }
413+ }
410414 if ($env: update -eq ' true' ) {
411415 Update-Php $php_dir > $null 2>&1
412416 $status = " Updated to"
0 commit comments