speccrew 0.7.44 → 0.7.45
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -439,7 +439,11 @@ function cmdInit(args) {
|
|
|
439
439
|
// Read task list from argument or file
|
|
440
440
|
if (args.tasksFile) {
|
|
441
441
|
// Read from file
|
|
442
|
-
|
|
442
|
+
let tasksContent = fs.readFileSync(path.resolve(args.tasksFile), 'utf8');
|
|
443
|
+
// Strip UTF-8 BOM if present
|
|
444
|
+
if (tasksContent.charCodeAt(0) === 0xFEFF) {
|
|
445
|
+
tasksContent = tasksContent.slice(1);
|
|
446
|
+
}
|
|
443
447
|
try {
|
|
444
448
|
tasks = JSON.parse(tasksContent);
|
|
445
449
|
} catch (e) {
|