Skip to content

Commit

Permalink
add event for manifest.json
Browse files Browse the repository at this point in the history
  • Loading branch information
pelinisildar committed Oct 12, 2022
1 parent a2295f0 commit 1c74350
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions bin/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ const options = yargs
fs.mkdirSync(path.join(folderPath, 'functions'));
fs.mkdirSync(path.join(folderPath, 'models'));
fs.mkdirSync(path.join(folderPath, 'configurations'));
fs.mkdirSync(path.join(folderPath, 'events'));

if (config.extension && config.extension.components) {

Expand Down Expand Up @@ -99,6 +100,11 @@ const options = yargs
fs.writeFileSync(path.join(folderPath, 'configurations', 'manifest.json'), JSON.stringify({ content: config.extension.configuration }));
}

if (config.extension && config.extension.events) {

fs.writeFileSync(path.join(folderPath, 'events', 'manifest.json'), JSON.stringify({ contents: config.extension.events }));
}

var zipFile = Math.floor(Date.now() / 1000).toString();
var zipPath = path.join('./fow-packages', zipFile + '.zip')
zip.zip(folderPath, zipPath).then(() => {
Expand Down

0 comments on commit 1c74350

Please sign in to comment.