Look for version-manifest.json relative to action path (#456)

Fixes: #455
This commit is contained in:
Kevin Stillhammer 2025-06-18 23:09:13 +02:00 committed by GitHub
parent 60cc2b4585
commit a02a550bdd
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 18 additions and 3 deletions

View file

@ -2,6 +2,9 @@ import { promises as fs } from "node:fs";
import * as core from "@actions/core";
import * as semver from "semver";
import { fetch } from "../utils/fetch";
import { join } from "node:path";
const localManifestFile = join(__dirname, "..", "..", "version-manifest.json");
interface ManifestEntry {
version: string;
@ -51,7 +54,7 @@ async function getManifestEntries(
data = await response.text();
} else {
core.info("manifest-file not provided, reading from local file.");
const fileContent = await fs.readFile("version-manifest.json");
const fileContent = await fs.readFile(localManifestFile);
data = fileContent.toString();
}