Output envs loaded by the dotenv instead of printing a source file content

This commit is contained in:
Alexey Igrychev
2021-03-18 12:13:58 +00:00
parent 1802a119b1
commit 23596d318c
7 changed files with 14 additions and 64 deletions

View File

@@ -43916,15 +43916,8 @@ class Manager {
const tmpFile = tmp.fileSync();
const tmpFilePath = tmpFile.name;
yield this.Exec(['ci-env', 'github', '--as-env-file', '-o', tmpFilePath]);
dotenv.config({ path: tmpFilePath });
fs.readFile(tmpFilePath, null, function (err, contents) {
if (err) {
console.error(err);
}
else {
console.log(contents.toString());
}
});
const res = dotenv.config({ path: tmpFilePath });
console.log(res.parsed);
tmpFile.removeCallback();
});
}