generator-module-maker
Version:
Node module scaffolding template with lots of optional badges
66 lines (60 loc) • 2.75 kB
JSON
{
"name": "<%= moduleName %>",
"version": "<%= moduleVersion %>",
"description": "<%= moduleDesc %>",
"main": "index.js",
"scripts": {
"lint": "eslint index.js",
"lint:fix": "eslint --fix index.js",
"dependencies": "npm-check",
"dependencies:fix": "npm-check -y",
"check": "run-s lint dependencies",
"test:watch": "jest --watchAll",
"test": "jest",
"test:coverage": "jest --coverage",<% if ( badges.includes( 'coveralls' ) ) { %>
"coveralls": "jest --coverage --coverageReporters=text-lcov | ./node_modules/coveralls/bin/coveralls.js",
"postcoveralls": "del-cli ./coverage", <% } %>
"prepublish": "jest",
"patch": "npm version patch && npm publish",
"minor": "npm version minor && npm publish",
"major": "npm version major && npm publish",
"prepublishOnly": "jest",
"postpublish": "git push origin master --follow-tags",
"save": "git commit -a --amend -C HEAD",
"changelog": "npx auto-changelog -p -l 10",
"marktoc": "npx replace -s -q '### Changelog' '<!-- START doctoc -->\\\n<!-- END doctoc -->' CHANGELOG.md",
"toc": "npx doctoc --github --title \"### Changelog\" CHANGELOG.md",
"preversion": "run-s -s lint dependencies gen-api add-api del-api",
"postversion": "run-s -s changelog marktoc toc save",
"add-api": "node -e \"const x='README',{readFileSync:_r,writeFileSync:w}=require('fs'),r=f=>_r(f+'.md','utf8'),s=r(x),t='<!-- APIS -->\\n'+r('tmp')+'<!-- APIE -->';w(x+'.md',s.replace(/<!-- APIS -->[\\s\\S]*<!-- APIE -->/,t))\"",
"gen-api": "npx jsdoc-to-markdown index.js > tmp.md",
"del-api": "del-cli tmp.md",
"api": "run-s -s gen-api add-api del-api",
"docs": "npx documentation readme index.js --infer-private='^_.*' -s API --github",
"docsite": "npx documentation build index.js --infer-private='^_.*' -f html -o docs"
},
"repository": {
"type": "git",
"url": "git+<%= repository %>.git"
},
"keywords": [
<% moduleKeywords.forEach(function(keyword, i, arr) { %>"<%= keyword %>"<% if (i !== arr.length - 1) { %>,
<% } %><% }); %>
],
"author": "<%= name %> <<%= email %>>",
"license": "MIT",
"bugs": {
"url": "<%= repository %>/issues"
},
"homepage": "<%= repository %>#readme",
"devDependencies": {
"eslint": "^5.14.1",
"jest": "^24.1.0",
"npm-check": "^5.9.0",
"npm-run-all": "^4.1.5",<% if ( badges.includes( 'coveralls' ) ) { %>
"coveralls": "^3.0.3",<% } %>
"del-cli": "^1.1.0",
"@types/jasmine": "^3.3.9",
"@types/jest": "^24.0.9"
}
}