Skip to content

Commit

Permalink
build: fix Appveyor test workflow checkout (electron#39137)
Browse files Browse the repository at this point in the history
* build: fix Appveyor test workflow checkout

* fix: +refs/pull/num/merge -> +refs/pull/num/head

* chore: add to appveyor-woa as well
  • Loading branch information
codebytere authored Jul 20, 2023
1 parent 565705b commit 6688b0f
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
5 changes: 5 additions & 0 deletions appveyor-woa.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,11 @@ environment:
APPVEYOR_BUILD_WORKER_IMAGE: base-woa
APPVEYOR_BUILD_WORKER_CLOUD: electronhq-woa

clone_script:
- ps: git clone -q $("--branch=" + $Env:APPVEYOR_REPO_BRANCH) $("https://github.com/" + $Env:APPVEYOR_REPO_NAME + ".git") $Env:APPVEYOR_BUILD_FOLDER
- ps: if (!$Env:APPVEYOR_PULL_REQUEST_NUMBER) {$("git checkout -qf " + $Env:APPVEYOR_REPO_COMMIT)}
- ps: if ($Env:APPVEYOR_PULL_REQUEST_NUMBER) {git fetch -q origin +refs/pull/$($Env:APPVEYOR_PULL_REQUEST_NUMBER)/head; git checkout -qf FETCH_HEAD}

clone_folder: C:\projects\src\electron

skip_branch_with_pr: true
Expand Down
5 changes: 5 additions & 0 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,11 @@ environment:
- job_name: Test
job_depends_on: Build

clone_script:
- ps: git clone -q $("--branch=" + $Env:APPVEYOR_REPO_BRANCH) $("https://github.com/" + $Env:APPVEYOR_REPO_NAME + ".git") $Env:APPVEYOR_BUILD_FOLDER
- ps: if (!$Env:APPVEYOR_PULL_REQUEST_NUMBER) {$("git checkout -qf " + $Env:APPVEYOR_REPO_COMMIT)}
- ps: if ($Env:APPVEYOR_PULL_REQUEST_NUMBER) {git fetch -q origin +refs/pull/$($Env:APPVEYOR_PULL_REQUEST_NUMBER)/head; git checkout -qf FETCH_HEAD}

clone_folder: C:\projects\src\electron

skip_branch_with_pr: true
Expand Down

0 comments on commit 6688b0f

Please sign in to comment.