Skip to content

Commit

Permalink
+5
Browse files Browse the repository at this point in the history
  • Loading branch information
SunSerega committed Aug 31, 2024
1 parent d89e4a9 commit 213af71
Showing 1 changed file with 26 additions and 19 deletions.
45 changes: 26 additions & 19 deletions .github/workflows/upstream pretest.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -188,13 +188,13 @@ jobs:
param ($ref, $key)
$pattern = "^meta\.$key=([0-9a-f]{40})$"
# Write-Host "--- Looking for commit message lines matching [$pattern]"
Write-Host "--- Looking for commit message lines matching [$pattern]"
$res = @()
foreach ($l in git log -1 --pretty=format:"%B" $ref) {
# Write-Host "----- $l"
Write-Host "----- $l"
if ($l -notmatch $pattern) { continue }
$sha = $matches[1]
# Write-Host "------- FOUND: $sha"
Write-Host "------- FOUND: $sha"
$res += $sha
}
if (-not $?) { throw "git log failed" }
Expand Down Expand Up @@ -463,27 +463,34 @@ jobs:
Write-Host "=============================="
git config -l
if (-not $?) { throw "git config -l failed" }
Write-Host "=============================="
# Write-Host "=============================="
# git config -l
# if (-not $?) { throw "git config -l failed" }
# Write-Host "=============================="
$main_repo_dir = './core'
New-Item -ItemType Directory -Path $main_repo_dir | Out-Null
Push-Location $main_repo_dir
$main_repo_url = '${{ github.server_url }}/${{ github.repository }}'
Write-Host "Cloning main repo [$main_repo_url]"
git init
if (-not $?) { throw "git init failed" }
git config --local http.https://github.com/.extraheader "AUTHORIZATION: basic ${{ github.token }}"
if (-not $?) { throw "git config failed" }
Write-Host "=============================="
git config -l
if (-not $?) { throw "git config -l failed" }
Write-Host "=============================="
git remote add origin $main_repo_url
if (-not $?) { throw "git remote add failed" }
git -c protocol.version=2 fetch --no-tags --prune --depth=1 origin --filter=tree:0 --no-progress
if (-not $?) { throw "git fetch failed" }
git clone --filter=tree:0 --no-progress --no-checkout $main_repo_url .
if (-not $?) { throw "git clone failed" }
# git init
# if (-not $?) { throw "git init failed" }
# git config --local http.https://github.com/.extraheader "AUTHORIZATION: basic ${{ github.token }}"
# if (-not $?) { throw "git config failed" }
# Write-Host "=============================="
# git config -l
# if (-not $?) { throw "git config -l failed" }
# Write-Host "=============================="
# git remote add origin $main_repo_url
# if (-not $?) { throw "git remote add failed" }
# git -c protocol.version=2 fetch --no-tags --prune --depth=1 origin --filter=tree:0 --no-progress
# if (-not $?) { throw "git fetch failed" }
# git branch -r
Expand Down

0 comments on commit 213af71

Please sign in to comment.