Compare commits
2 Commits
51e22a4611
...
8922d96c55
Author | SHA1 | Date |
---|---|---|
|
8922d96c55 | |
|
1dc8eb0166 |
|
@ -19,8 +19,7 @@ const storage = new Storage({
|
|||
});
|
||||
|
||||
const title = "LingDocs Pashto Dictionary";
|
||||
const license =
|
||||
"Copyright © 2021 lingdocs.com All Rights Reserved - Licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License - https://creativecommons.org/licenses/by-nc-sa/4.0/";
|
||||
const license = `Copyright © ${new Date().getFullYear()} lingdocs.com All Rights Reserved - Licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License - https://creativecommons.org/licenses/by-nc-sa/4.0/`;
|
||||
const bucketName = "lingdocs";
|
||||
const baseUrl = `https://storage.googleapis.com/${bucketName}/`;
|
||||
const dictionaryFilename = "dictionary";
|
||||
|
@ -260,7 +259,10 @@ async function uploadDictionaryToStorage(dictionary: T.Dictionary) {
|
|||
const dictionaryInfoBuffer = writeDictionaryInfo(dictionary.info);
|
||||
await Promise.all([
|
||||
upload(JSON.stringify(dictionary), `${dictionaryFilename}.json`),
|
||||
upload(JSON.stringify(dictionary.info), `${dictionaryInfoFilename}.json`),
|
||||
upload(
|
||||
JSON.stringify(dictionary.info, null, "\t"),
|
||||
`${dictionaryInfoFilename}.json`
|
||||
),
|
||||
upload(dictionaryBuffer as Buffer, dictionaryFilename),
|
||||
upload(dictionaryInfoBuffer as Buffer, dictionaryInfoFilename),
|
||||
]);
|
||||
|
|
Loading…
Reference in New Issue