Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 21 additions & 27 deletions .github/workflows/build-concurrently.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,35 +42,29 @@ jobs:

const fs = require('fs');
const path = require('path');

module.exports = ({core}) => {
try {
let projectPaths = [];

function findProjectXmlFiles(dir) {
const filesAndDirs = fs.readdirSync(dir, {withFileTypes: true});

for (const item of filesAndDirs) {
const fullPath = path.join(dir, item.name);
if (item.isDirectory())
findProjectXmlFiles(fullPath);
else if (item.isFile() && item.name.match(/project.xml/i))
projectPaths.push(dir);

}
}

findProjectXmlFiles("./");

console.log(projectPaths);

try {
let projectPaths = [];
function findProjectXmlFiles(dir) {
const filesAndDirs = fs.readdirSync(dir, {withFileTypes: true});

return projectPaths;
} catch (error) {
core.setFailed(error.message);
for (const item of filesAndDirs)
{
const fullPath = path.join(dir, item.name);
if (item.isDirectory())
findProjectXmlFiles(fullPath);
else if (item.isFile() && item.name.match(/project.xml/i))
projectPaths.push(dir);
}
}

findProjectXmlFiles("./");
console.log(projectPaths);
return projectPaths;
} catch (error) {
core.setFailed(error.message);
}



build-demo:
runs-on: ubuntu-latest
needs: get-demos
Expand Down Expand Up @@ -137,4 +131,4 @@ jobs:
github_token: ${{secrets.GITHUB_TOKEN}}
publish_dir: out
force_orphan: true
cname: demos.haxeflixel.com
cname: demos.haxeflixel.com
Loading