Skip to content
This repository was archived by the owner on Jan 15, 2025. It is now read-only.

Commit 4e6ad65

Browse files
author
Jonathan Spruance (Insight Global)
committed
Show error if no file contents found
1 parent 26ac202 commit 4e6ad65

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

packages/chatdown/src/commands/chatdown.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,8 @@ export default class Chatdown extends Command {
5858
if (typeof writeConfirmation === 'string') {
5959
process.stdout.write(`${chalk.green('Successfully wrote file:')} ${writeConfirmation}\n`)
6060
}
61+
} else if (flags.in && !fileContents){
62+
throw new CLIError('No file contents found in: ' + flags.in)
6163
} else {
6264
return this._help()
6365
}

0 commit comments

Comments
 (0)