From 3b13afa9ab71272f63805070d3d70b36f8421b2b Mon Sep 17 00:00:00 2001 From: Matt McFarland Date: Thu, 21 Mar 2013 15:04:32 -0500 Subject: [PATCH] clean up bin script --- bin/artificer | 12 +++++++----- package.json | 5 ++++- 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/bin/artificer b/bin/artificer index a856c74..5a20654 100755 --- a/bin/artificer +++ b/bin/artificer @@ -15,10 +15,11 @@ var artificer = require('../'), commander .version(package.version) + .option('-v, --verbose', 'output verbose logging messages') + .option('-t, --title [NAME]', 'set the title on generated pages', '') .option('-s, --source [PATH]', 'source directory path - must be a directory', '') .option('-d, --destination [PATH]', 'destination directory path - must not exist', '') - .option('-c, --config [NAME]', 'change the default name artificer uses for configuration files') - .option('-t, --title [NAME]', 'set the title on generated pages', '') + .option('-l, --layout [PATH]' 'handlebars layout to use for render - {{title}} and {{content}} are passed') .parse(process.argv); /** @@ -33,16 +34,17 @@ if(!src || !dest) { } if(!utils.exists(src) || utils.isFile(src)) { - process.stdout.write(' Source directory does not exist'); + process.stdout.write(' Source directory does not exist.\n'); commander.help(); } if(utils.exists(dest)) { - process.stdout.write(' Destination already exists on the filesystem'); + process.stdout.write(' Destination already exists on the filesystem.\n'); commander.help(); } artificer(src, dest, { title: commander.title, - config: commander.config + config: commander.config, + verbose: commander.verbose }); diff --git a/package.json b/package.json index 2dc6a9d..d40e8a7 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "artificer", - "version": "0.0.0", + "version": "0.0.1", "description": "Markdown to html site generator.", "author": "vanetix", "main": "index.js", @@ -8,6 +8,9 @@ "type": "git", "url": "https://github.com/vanetix/artificer.git" }, + "bin": { + "artificer": "./bin/artificer" + }, "keywords": [ "static", "site",