Skip to content

Commit abcc61d

Browse files
committed
Patch to avoid abbreviated git hash collisions
1 parent 86c9b8e commit abcc61d

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

.github/workflows/php80.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,15 +70,20 @@ jobs:
7070
$tar_location="C:\Program Files\Git\usr\bin\tar.exe"
7171
$task_location="C:\php-snap-build\rmtools\bin\snapshot_task.bat"
7272
$git_script_location="C:\php-snap-build\rmtools\include\Git.php"
73+
$snap_script_location="C:\php-snap-build\rmtools\script\snap.php"
74+
$branch_script_location="C:\php-snap-build\rmtools\include\Branch.php"
7375
$config_location="C:\php-snap-build\rmtools\data\config\branch\${{ matrix.arch }}\php80.ini"
7476
((Get-Content -path $git_script_location -Raw) -replace "c:\\apps\\git\\bin\\git.exe", $git_location) | Set-Content -Path $git_script_location
7577
((Get-Content -path $git_script_location -Raw) -replace "c:\\apps\\git\\bin\\tar.exe", $tar_location) | Set-Content -Path $git_script_location
7678
((Get-Content -path $task_location -Raw) -replace ">> %LOG_FILE% 2<&1", "") | Set-Content -Path $task_location
79+
((Get-Content -path $snap_script_location -Raw) -replace "0, 7", "0, 10") | Set-Content -Path $snap_script_location
80+
((Get-Content -path $branch_script_location -Raw) -replace "0, 7", "0, 10") | Set-Content -Path $branch_script_location
7781
((Get-Content -path $config_location -Raw) -replace "pgo=1", "pgo=0") | Set-Content -Path $config_location
7882
- name: build PHP
7983
run: |
8084
$ErrorActionPreference = "Stop"
8185
& C:\php-snap-build\php-sdk\phpsdk-vs16-${{ matrix.arch }}.bat -t C:\php-snap-build\rmtools\bin\snapshot_task.bat --task-args "php80 ${{ matrix.config }}"
86+
Get-ChildItem C:/php-snap-build/${{ matrix.target }} -Recurse
8287
- name: Collect Artifacts
8388
run: |
8489
New-Item -ItemType "directory" -Path builds

.github/workflows/phpmaster.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,15 +70,20 @@ jobs:
7070
$tar_location="C:\Program Files\Git\usr\bin\tar.exe"
7171
$task_location="C:\php-snap-build\rmtools\bin\snapshot_task.bat"
7272
$git_script_location="C:\php-snap-build\rmtools\include\Git.php"
73+
$snap_script_location="C:\php-snap-build\rmtools\script\snap.php"
74+
$branch_script_location="C:\php-snap-build\rmtools\include\Branch.php"
7375
$config_location="C:\php-snap-build\rmtools\data\config\branch\${{ matrix.arch }}\phpmaster.ini"
7476
((Get-Content -path $git_script_location -Raw) -replace "c:\\apps\\git\\bin\\git.exe", $git_location) | Set-Content -Path $git_script_location
7577
((Get-Content -path $git_script_location -Raw) -replace "c:\\apps\\git\\bin\\tar.exe", $tar_location) | Set-Content -Path $git_script_location
7678
((Get-Content -path $task_location -Raw) -replace ">> %LOG_FILE% 2<&1", "") | Set-Content -Path $task_location
79+
((Get-Content -path $snap_script_location -Raw) -replace "0, 7", "0, 10") | Set-Content -Path $snap_script_location
80+
((Get-Content -path $branch_script_location -Raw) -replace "0, 7", "0, 10") | Set-Content -Path $branch_script_location
7781
((Get-Content -path $config_location -Raw) -replace "pgo=1", "pgo=0") | Set-Content -Path $config_location
7882
- name: build PHP
7983
run: |
8084
$ErrorActionPreference = "Stop"
8185
& C:\php-snap-build\php-sdk\phpsdk-vs16-${{ matrix.arch }}.bat -t C:\php-snap-build\rmtools\bin\snapshot_task.bat --task-args "phpmaster ${{ matrix.config }}"
86+
Get-ChildItem C:/php-snap-build/${{ matrix.target }} -Recurse
8287
- name: Collect Artifacts
8388
run: |
8489
$php_version = Invoke-RestMethod https://raw.githubusercontent.com/php/php-src/master/main/php_version.h | Where-Object { $_ -match 'PHP_VERSION "(.*)"' } | Foreach-Object {$Matches[1]}

0 commit comments

Comments
 (0)