Initial commit
Some checks failed
Check Transpiled JavaScript / Check dist/ (push) Successful in 55s
Continuous Integration / TypeScript Tests (push) Successful in 56s
Continuous Integration / GitHub Actions Test (push) Successful in 10s
Lint Codebase / Lint Codebase (push) Failing after 7m55s

This commit is contained in:
2025-01-11 22:39:23 +01:00
commit 3999529881
43 changed files with 38960 additions and 0 deletions

8
src/index.ts Normal file
View File

@@ -0,0 +1,8 @@
/**
* The entrypoint for the action. This file simply imports and runs the action's
* main logic.
*/
import { run } from './main.js';
/* istanbul ignore next */
run();

19
src/main.ts Normal file
View File

@@ -0,0 +1,19 @@
import * as core from '@actions/core';
import * as fs from 'fs';
/**
* The main function for the action.
*
* @returns Resolves when the action is complete.
*/
export async function run(): Promise<void> {
try {
const bakefile: string = core.getInput('bakefile', { required: true });
const metadata = JSON.parse(fs.readFileSync(bakefile, 'utf-8'));
core.info(`Metadata: ${JSON.stringify(metadata)}`);
// core.info(`Bakefile:\t${bakefile}`);
} catch (error) {
// Fail the workflow run if an error occurs
if (error instanceof Error) core.setFailed(error.message);
}
}