Skip to content

Commit

Permalink
exit if no config file was found
Browse files Browse the repository at this point in the history
  • Loading branch information
Lifeismana committed Nov 26, 2024
1 parent a752ffd commit 4a51945
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ export default class Config {
this.verify();
} catch (err) {
console.error(err);
if (err.code === "ENOENT") {
console.error(`Config file not found, it should be under ${CONFIG_FILE}`);
process.exit(1);
}
}
this.#watch();
}
Expand Down

0 comments on commit 4a51945

Please sign in to comment.