Skip to content

Commit

Permalink
Merge branch 'release/0.2.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
vimkat committed Aug 30, 2018
2 parents 238dbcc + 0681368 commit a23ed5b
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
10 changes: 9 additions & 1 deletion main.js
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ targetConfiguration.targets.forEach(target => {

// Create target archive and write stream.
const categoryArchive = archiver('zip')
categoryArchive.pipe(fs.createWriteStream(path.join(targetPath, `${category.name}.zip`)))
categoryArchive.pipe(fs.createWriteStream(path.join(targetPath, `${sanitizeFilename(category.name)}.zip`)))

// Process all emojis in this category.
const emojiBufferPromises = category.emojis.map(async (emoji) => {
Expand Down Expand Up @@ -148,5 +148,13 @@ targetConfiguration.targets.forEach(target => {
})


function sanitizeFilename(filename) {
return filename
.replace(/&/g, 'and')
.replace(/\s/g, '_')
.toLowerCase()
}


////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "notes-sametime-emojis",
"version": "0.1.0",
"version": "0.2.0",
"description": "",
"main": "main.js",
"scripts": {
Expand Down

0 comments on commit a23ed5b

Please sign in to comment.