forked from gridaco/assistant
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
9c59b9e
commit 4a38093
Showing
2 changed files
with
17 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
// before publishing update to figma, clean the dist forder for the size reduction. | ||
// leave only dist/code.js and dist/ui.js under the dist folder (remove all other files) | ||
|
||
const fs = require("fs"); | ||
const path = require("path"); | ||
|
||
const distPath = path.join(__dirname, "../dist"); | ||
|
||
fs.readdirSync(distPath).forEach((file) => { | ||
if (file !== "code.js" && file !== "ui.js") { | ||
fs.unlink(path.join(distPath, file), (err) => { | ||
if (err) throw err; | ||
}); | ||
} | ||
}); |