Add quiet input to suppress info-level log output (#898)

## Summary

Adds a new `quiet` input (default: `false`) that suppresses `info`-level
log output when set to `true`. Only warnings and errors are shown.

Contributes to: #868
This commit is contained in:
Kevin Stillhammer
2026-05-31 21:13:30 +02:00
committed by GitHub
parent e07f2ac4b7
commit a92cb43098
18 changed files with 705 additions and 612 deletions

View File

@@ -1,6 +1,7 @@
import * as core from "@actions/core";
import { VERSIONS_MANIFEST_URL } from "../utils/constants";
import { fetch } from "../utils/fetch";
import * as log from "../utils/logging";
import { selectDefaultVariant } from "./variant-selection";
export interface ManifestArtifact {
@@ -33,7 +34,7 @@ export async function fetchManifest(
return cachedVersions;
}
core.info(`Fetching manifest data from ${manifestUrl} ...`);
log.info(`Fetching manifest data from ${manifestUrl} ...`);
const response = await fetch(manifestUrl, {});
if (!response.ok) {
throw new Error(
@@ -111,7 +112,7 @@ export async function getLatestVersion(
export async function getAllVersions(
manifestUrl: string = VERSIONS_MANIFEST_URL,
): Promise<string[]> {
core.info(
log.info(
`Getting available versions from ${manifestSource(manifestUrl)} ...`,
);
const versions = await fetchManifest(manifestUrl);