Skip to content

Commit

Permalink
Debug logging
Browse files Browse the repository at this point in the history
  • Loading branch information
debugger22 committed Aug 11, 2020
1 parent 74bb611 commit 9c36474
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 6 deletions.
8 changes: 5 additions & 3 deletions dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -63,14 +63,16 @@ const main = async () => {
const filePaths = core.getInput('files').split(" ");
console.log(filePaths);
var output = "";
filePaths.forEach(async(filePath) =>{
console.log(filePath);
filePaths.forEach(async(filePath) => {

if(filePath.includes("migrations")){
output += `==========================${filePath}==========================\n\n`;
const content = await fs.readFile(filePath, 'utf8');
output += content + "\n\n";
console.log(content);
console.log(output);

}

});
core.setOutput('content', output);
}
Expand Down
8 changes: 5 additions & 3 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,16 @@ const main = async () => {
const filePaths = core.getInput('files').split(" ");
console.log(filePaths);
var output = "";
filePaths.forEach(async(filePath) =>{
console.log(filePath);
filePaths.forEach(async(filePath) => {

if(filePath.includes("migrations")){
output += `==========================${filePath}==========================\n\n`;
const content = await fs.readFile(filePath, 'utf8');
output += content + "\n\n";
console.log(content);
console.log(output);

}

});
core.setOutput('content', output);
}
Expand Down

0 comments on commit 9c36474

Please sign in to comment.