Add workflow input to disable uploads

This commit is contained in:
Robert 2021-06-18 09:56:15 +01:00
parent 33ac512514
commit f3cd5fa001
4 changed files with 14 additions and 1 deletions

View file

@ -58,6 +58,11 @@ async function uploadDatabases(
apiDetails: GitHubApiDetails,
logger: Logger
): Promise<void> {
if (actionsUtil.getRequiredInput("upload-database") !== "true") {
logger.debug("Database upload disabled in workflow. Skipping upload.");
return;
}
// Do nothing when not running against github.com
if (config.gitHubVersion.type !== util.GitHubVariant.DOTCOM) {
logger.debug("Not running against github.com. Skipping upload.");