diff --git a/test.js b/test.js index 111c35df..3bd29b8d 100644 --- a/test.js +++ b/test.js @@ -27,8 +27,13 @@ function report(content, fix) { try { const data = await readFile(path.join('users', user), "utf8") try { - const u = JSON.parse(data); + let u = JSON.parse(data); if (!u.locked && !u.copyright) report(`Copyright not specified in ${user}`) + if (u.version) report(`Version tag found in ${user}`, () => { + delete u.version + const stringified = `${JSON.stringify(u, 0, 2)}\n` + fs.writeFile(path.join('users', user), stringified, () => { }) + }) const stringified = `${JSON.stringify(u, 0, 2)}\n` if (data !== stringified) report(`Non-regular formatting in ${user}`, () => fs.writeFile(path.join('users', user), stringified, () => {})) } catch ({ diff --git a/users/codeclarity-jquerytools.json b/users/codeclarity-jquerytools.json index 30b78e81..167fe2c7 100644 --- a/users/codeclarity-jquerytools.json +++ b/users/codeclarity-jquerytools.json @@ -1,6 +1,5 @@ { "copyright": "Code Clarity", "theme": "double-windsor", - "email": "support@icodeclarity.com", - "version": "a526bf7ad1" + "email": "support@icodeclarity.com" } diff --git a/users/delphidabbler.json b/users/delphidabbler.json index 19615012..a414ece0 100644 --- a/users/delphidabbler.json +++ b/users/delphidabbler.json @@ -1,6 +1,5 @@ { "copyright": "Peter D Johnson", "url": "http://delphidabbler.com/", - "format": "text", - "version": "fdcf640" + "format": "text" } diff --git a/users/harry.json b/users/harry.json index 2342c893..17c84c1b 100644 --- a/users/harry.json +++ b/users/harry.json @@ -4,6 +4,5 @@ "email": "me@harryscheiner.com", "format": "html", "gravatar": true, - "version": "6d33a046", "theme": "default" } diff --git a/users/jesusurrutia.json b/users/jesusurrutia.json index f6b51246..03690ab0 100644 --- a/users/jesusurrutia.json +++ b/users/jesusurrutia.json @@ -2,7 +2,6 @@ "copyright": "Jesús Urrutia", "url": "http://jesusurrutia.com", "email": "jesus.urrutia@gmail.com", - "version": "html", "gravatar": true, "theme": "default" } diff --git a/users/mdag.json b/users/mdag.json index 76fc41af..cc2686eb 100644 --- a/users/mdag.json +++ b/users/mdag.json @@ -3,6 +3,5 @@ "url": "http://mdag.my", "email": "info+mitlicense@mdag.my", "format": "html", - "theme": "double-windsor", - "version": "a526bf7ad1" + "theme": "double-windsor" } diff --git a/yarn.lock b/yarn.lock index c53f2fc1..df84dee1 100644 Binary files a/yarn.lock and b/yarn.lock differ