Skip to content

Commit

Permalink
🐛 Add --skip-pull only with containers
Browse files Browse the repository at this point in the history
  • Loading branch information
tiulpin committed Aug 4, 2023
1 parent e47179c commit fd44f48
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 4 deletions.
4 changes: 3 additions & 1 deletion common/qodana.ts
Original file line number Diff line number Diff line change
Expand Up @@ -136,12 +136,14 @@ export function getQodanaScanArgs(
): string[] {
const cliArgs: string[] = [
'scan',
'--skip-pull',
'--cache-dir',
cacheDir,
'--results-dir',
resultsDir
]
if (!isNativeMode(args)) {
cliArgs.push('--skip-pull')
}
if (args) {
cliArgs.push(...args)
}
Expand Down
2 changes: 1 addition & 1 deletion scan/__tests__/main.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -169,11 +169,11 @@ export function inputsDefaultFixture(): Inputs {
export function defaultDockerRunCommandFixture(): string[] {
return [
'scan',
'--skip-pull',
'--cache-dir',
'${{ runner.temp }}/qodana-caches',
'--results-dir',
'${{ runner.temp }}/qodana-results',
'--skip-pull',
'--baseline',
'qodana.sarif.json'
]
Expand Down
4 changes: 3 additions & 1 deletion scan/dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -8628,12 +8628,14 @@ function getQodanaPullArgs(args) {
function getQodanaScanArgs(args, resultsDir, cacheDir) {
const cliArgs = [
"scan",
"--skip-pull",
"--cache-dir",
cacheDir,
"--results-dir",
resultsDir
];
if (!isNativeMode(args)) {
cliArgs.push("--skip-pull");
}
if (args) {
cliArgs.push(...args);
}
Expand Down
4 changes: 3 additions & 1 deletion vsts/QodanaScan/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -144,12 +144,14 @@ function getQodanaPullArgs(args) {
function getQodanaScanArgs(args, resultsDir, cacheDir) {
const cliArgs = [
"scan",
"--skip-pull",
"--cache-dir",
cacheDir,
"--results-dir",
resultsDir
];
if (!isNativeMode(args)) {
cliArgs.push("--skip-pull");
}
if (args) {
cliArgs.push(...args);
}
Expand Down

0 comments on commit fd44f48

Please sign in to comment.