Skip to content

Commit 5c02493

Browse files
authored
Merge pull request #2394 from rvermeulen/rvermeulen/extend-init-complete-status-report
Extend init complete status report
2 parents 3ec2588 + a8ab493 commit 5c02493

12 files changed

+94
-13
lines changed

lib/codeql.js

Lines changed: 1 addition & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/codeql.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/config-utils.js

Lines changed: 7 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/config-utils.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/init-action.js

Lines changed: 22 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/init-action.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/util.js

Lines changed: 4 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/util.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/codeql.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ import * as setupCodeql from "./setup-codeql";
3131
import { ToolsFeature, isSupportedToolsFeature } from "./tools-features";
3232
import { shouldEnableIndirectTracing } from "./tracer-config";
3333
import * as util from "./util";
34-
import { BuildMode, wrapError } from "./util";
34+
import { BuildMode, wrapError, cloneObject } from "./util";
3535

3636
type Options = Array<string | number | boolean>;
3737

@@ -1306,10 +1306,6 @@ async function generateCodeScanningConfig(
13061306
return codeScanningConfigFile;
13071307
}
13081308

1309-
function cloneObject<T>(obj: T): T {
1310-
return JSON.parse(JSON.stringify(obj)) as T;
1311-
}
1312-
13131309
// This constant sets the size of each TRAP cache in megabytes.
13141310
const TRAP_CACHE_SIZE_MB = 1024;
13151311

src/config-utils.ts

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -881,6 +881,15 @@ function parseRegistries(
881881
}
882882
}
883883

884+
export function parseRegistriesWithoutCredentials(
885+
registriesInput?: string,
886+
): RegistryConfigNoCredentials[] | undefined {
887+
return parseRegistries(registriesInput)?.map((r) => {
888+
const { url, packages } = r;
889+
return { url, packages };
890+
});
891+
}
892+
884893
function isLocal(configPath: string): boolean {
885894
// If the path starts with ./, look locally
886895
if (configPath.indexOf("./") === 0) {

0 commit comments

Comments
 (0)