copyright for ts

This commit is contained in:
Timo Hocker 2020-04-08 19:32:19 +02:00
parent 82af221062
commit 28872f5f5d

View File

@ -86,7 +86,7 @@ async function fix_all_copy (folder, license = '', software = '') {
await map_all_files (folder, (data, filename) => {
const shebang = /^#!.*?\n\n/gu;
const shebang_line = shebang.exec (data);
if (!(/\.js$/u).test (filename) && !regex.test (data))
if (!(/\.(?:js|ts|mjs)$/u).test (filename) && !regex.test (data))
return null;
return (shebang_line ? shebang_line[0] : '')
+ get_copyright_notice (license, software)