Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update window openjdk git clone repo #143

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 12 additions & 1 deletion dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -436,7 +436,18 @@ function getAqaTestsRepo(aqatestsRepo, version, buildList) {
if (buildList === 'openjdk' && version != '') {
process.chdir('openjdk');
// Shallow clone the adoptium JDK version - quietly - if there is a reference repo obtain objects from there - destination is openjdk-jdk
yield exec.exec(`git clone --depth 1 -q --reference-if-able ${process.env.GITHUB_WORKSPACE}/openjdk_cache https://github.com/adoptium/jdk${version}.git openjdk-jdk`);
try {
let openJDKGitCmd = "git clone --depth 1 -q --reference-if-able ${process.env.GITHUB_WORKSPACE}/openjdk_cache https://github.com/adoptium/jdk${version}";
const exitCode = yield exec.exec(`git ls-remote -h https://github.com/adoptium/jdk${version}u.git`);
if (exitCode == 0) {
openJDKGitCmd += 'u';
}
openJDKGitCmd += '.git openjdk-jdk';
yield exec.exec(`${openJDKGitCmd}`);
}
catch (err) {
console.error("Git clone openjdk error", err);
}
process.chdir('../');
}
}
Expand Down
12 changes: 11 additions & 1 deletion src/runaqa.ts
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,17 @@ async function getAqaTestsRepo(aqatestsRepo: string, version: string, buildList:
if (buildList === 'openjdk' && version != '') {
process.chdir('openjdk')
// Shallow clone the adoptium JDK version - quietly - if there is a reference repo obtain objects from there - destination is openjdk-jdk
await exec.exec(`git clone --depth 1 -q --reference-if-able ${process.env.GITHUB_WORKSPACE}/openjdk_cache https://github.com/adoptium/jdk${version}.git openjdk-jdk`)
try {
let openJDKGitCmd = "git clone --depth 1 -q --reference-if-able ${process.env.GITHUB_WORKSPACE}/openjdk_cache https://github.com/adoptium/jdk${version}"
const exitCode = await exec.exec(`git ls-remote -h https://github.com/adoptium/jdk${version}u.git`)
if (exitCode == 0) {
openJDKGitCmd += 'u'
}
openJDKGitCmd += '.git openjdk-jdk'
await exec.exec(`${openJDKGitCmd}`)
} catch (err) {
console.error("Git clone openjdk error", err)
}
process.chdir('../')
}
}
Expand Down
Loading