mirror of
https://github.com/namibia/tips.git
synced 2024-11-13 16:56:30 +00:00
commit
885357aa83
@ -1,4 +1,3 @@
|
||||
var tips = require('./tips.json');
|
||||
// from https://gist.github.com/mathewbyrne/1280286
|
||||
slugify = function(text){
|
||||
return text.toString().toLowerCase()
|
||||
@ -14,7 +13,6 @@ var render = function(data) {
|
||||
|
||||
var out = '* [' + data.title + '](https://github.com/git-tips/tips#' + slugify(data.title) + ')\n';
|
||||
|
||||
if (tips[tips.length -1].title === data.title) out = out + '\n';
|
||||
return out;
|
||||
};
|
||||
|
||||
|
@ -8,7 +8,7 @@
|
||||
"test": "echo \"Error: no test specified\" && exit 1",
|
||||
"precommit": "npm run generate && git add README.md",
|
||||
"update-readme": "echo 'Updating the readme…'; doxie --render < ./tips.json --inject into README.md && echo '…done!'",
|
||||
"update-toc": "echo 'Updating the table of contents…'; doxie --render .doxie.render.toc.js < ./tips.json --inject into README.md as toc && echo '…done!'",
|
||||
"update-toc": "echo 'Updating the table of contents…'; doxie --render .doxie.render.toc.js < ./tips.json --append '\n' --inject into README.md as toc && echo '…done!'",
|
||||
"generate": "npm run update-readme; npm run update-toc"
|
||||
},
|
||||
"repository": {
|
||||
@ -29,6 +29,7 @@
|
||||
"homepage": "https://github.com/git-tips/tips#readme",
|
||||
"devDependencies": {
|
||||
"doxie": "^0.2.2",
|
||||
"doxie.append": "^0.1.0",
|
||||
"doxie.inject": "^0.1.1",
|
||||
"doxie.output": "^0.3.0",
|
||||
"doxie.render": "^0.3.0",
|
||||
|
Loading…
Reference in New Issue
Block a user