Revert convert to esm (#544)

* Revert "update got dependency and convert to esm module (#533)"

This reverts commit 77efb36ae3.

* keep new local test file changes

* keep changes to PR template

* update changelog
This commit is contained in:
John-Michael Faircloth 2024-04-15 16:39:55 -05:00 committed by GitHub
parent ee41aa2fcf
commit 66531b2752
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
39 changed files with 14341 additions and 12232 deletions

View file

@ -1,11 +1,7 @@
import core from '@actions/core';
import { WILDCARD } from './constants.js';
import { normalizeOutputKey } from './utils.js';
// ncc doesn't compile jsonata imports properly, so we must use our own custom require
import require from "./cjs-require.js";
const jsonata = require('jsonata');
const jsonata = require("jsonata");
const { WILDCARD } = require("./constants");
const { normalizeOutputKey } = require("./utils");
const core = require('@actions/core');
/**
* @typedef {Object} SecretRequest
@ -48,7 +44,7 @@ async function getSecrets(secretRequests, client, ignoreNotFound) {
} catch (error) {
const {response} = error;
if (response?.statusCode === 404) {
let notFoundMsg = `Unable to retrieve result for "${path}" because it was not found: ${response.body.trim()}`;
notFoundMsg = `Unable to retrieve result for "${path}" because it was not found: ${response.body.trim()}`;
const ignoreNotFound = (core.getInput('ignoreNotFound', { required: false }) || 'false').toLowerCase() != 'false';
if (ignoreNotFound) {
core.error(`${notFoundMsg}`);
@ -169,7 +165,7 @@ const selectAndAppendResults = async (
];
};
export {
module.exports = {
getSecrets,
selectData
}