Conversation
There was a problem hiding this comment.
Pull request overview
Updates the Windows dependency install/build script to “refresh” already-cloned source repos during builds.
Changes:
- Adds
git pull --recurse-submodulesafter checking out OpenVINO, Tokenizers, and GenAI sources.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| if !errorlevel! neq 0 exit /b !errorlevel! | ||
| git submodule update --init --recursive | ||
| if !errorlevel! neq 0 exit /b !errorlevel! | ||
| git pull --recurse-submodules |
There was a problem hiding this comment.
OV_SOURCE_BRANCH defaults to a specific commit SHA (detached HEAD). Running git pull in detached HEAD will fail ("You are not currently on a branch") and is also ignored here (no errorlevel check). Consider removing this pull, or only pulling when %OV_SOURCE_BRANCH% is an actual branch name; for pinned SHAs, git fetch + git checkout is sufficient and keeps builds reproducible.
| git pull --recurse-submodules | |
| for /f "delims=" %%i in ('git symbolic-ref --short -q HEAD 2^>nul') do set "GIT_CURRENT_BRANCH=%%i" | |
| if defined GIT_CURRENT_BRANCH ( | |
| git pull --recurse-submodules | |
| ) |
| git fetch origin | ||
| git checkout %TOKENIZER_SOURCE_BRANCH% | ||
| if !errorlevel! neq 0 exit /b !errorlevel! | ||
| git pull --recurse-submodules |
There was a problem hiding this comment.
TOKENIZER_SOURCE_BRANCH defaults to a commit SHA, so this git pull will fail in detached HEAD and its failure is currently ignored (no errorlevel check). If the intent is to stay pinned, drop the pull; if the intent is to track a branch, gate the pull on being on a branch and ensure failure stops the script.
| git pull --recurse-submodules | |
| for /f "delims=" %%h in ('git rev-parse --abbrev-ref HEAD') do set "GIT_BRANCH=%%h" | |
| IF /I NOT "!GIT_BRANCH!"=="HEAD" ( | |
| git pull --recurse-submodules | |
| if !errorlevel! neq 0 exit /b !errorlevel! | |
| ) |
| git fetch origin | ||
| git checkout %GENAI_SOURCE_BRANCH% | ||
| if !errorlevel! neq 0 exit /b !errorlevel! | ||
| git pull --recurse-submodules |
There was a problem hiding this comment.
GENAI_SOURCE_BRANCH defaults to a commit SHA, which puts the repo in detached HEAD; git pull will fail in that state and the script does not check errorlevel afterwards. Recommend removing this pull (fetch+checkout already refreshes) or performing a deterministic update (e.g., fetch then reset/checkout the requested ref) with proper error handling.
| git pull --recurse-submodules |
🛠 Summary
refresh sources in CI for each build
🧪 Checklist
``