Skip to content

Commit

Permalink
fix: Show error message if config file missing (#3)
Browse files Browse the repository at this point in the history
  • Loading branch information
chardos authored and markdalgleish committed Nov 11, 2018
1 parent 7a2052b commit 7e9db88
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions bin/cli.js
Expand Up @@ -55,6 +55,11 @@ const showUsage = () => {
? path.resolve(cwd, args.config)
: await findUp('playroom.config.js', { cwd });

if (!configPath) {
console.error('Please add a playroom.config.js to the root of your project.');
process.exit(1);
}

const config = require(configPath);

const playroom = lib({
Expand Down

0 comments on commit 7e9db88

Please sign in to comment.