This commit is contained in:
parent
c5e6ac37fa
commit
3b63dda1d8
6
index.js
6
index.js
@ -19,12 +19,10 @@ const path = require("path");
|
||||
*/
|
||||
function replacePlaceholders(content) {
|
||||
const deployTime = new Date().toISOString();
|
||||
content = content
|
||||
return content
|
||||
.replace(/{{gitHash}}/g, process.env.GITHUB_SHA)
|
||||
.replace(/{{gitRef}}/g, process.env.GITHUB_REF)
|
||||
.replace(/{{deployTime}}/g, deployTime);
|
||||
core.info(content);
|
||||
return content;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -41,8 +39,6 @@ function replacePlaceholders(content) {
|
||||
async function readReplaceAndWriteFiles(pattern, prefix) {
|
||||
return new Promise((resolve, reject) => {
|
||||
const globPattern = prefix ? path.join(prefix, pattern) : pattern;
|
||||
core.info("globPattern");
|
||||
core.info(globPattern);
|
||||
|
||||
glob(globPattern, async (err, files) => {
|
||||
if (err) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user