mirror of
https://github.com/cappuccino/cappuccino.git
synced 2026-09-11 13:17:13 +00:00
Fixed stupid bug in figuring out what directory to watch
This commit is contained in:
@@ -127,16 +127,20 @@ function convert(options, inputFile)
|
||||
|
||||
function watch(options)
|
||||
{
|
||||
var verbosity = options.quiet ? -1 : options.verbosity;
|
||||
var verbosity = options.quiet ? -1 : options.verbosity,
|
||||
directory = options.args[0];
|
||||
|
||||
// Turn on info messages
|
||||
setLogLevel(1);
|
||||
if (!directory)
|
||||
directory = FILE.isDirectory("Resources") ? "Resources" : ".";
|
||||
|
||||
directory = FILE.canonical(options.args[0] || "Resources");
|
||||
directory = FILE.canonical(directory);
|
||||
|
||||
if (!FILE.isDirectory(directory))
|
||||
fail("Cannot find the directory: " + directory);
|
||||
|
||||
// Turn on info messages
|
||||
setLogLevel(1);
|
||||
|
||||
CPLog.info("Watching: " + CPLogColorize(directory, "debug"));
|
||||
CPLog.info("Press Control-C to stop...");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user