Skip to content

Commit 1deb3e3

Browse files
committed
[any message]
1 parent cd6168e commit 1deb3e3

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

app/main.js

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
const readline = require("readline");
22

3+
const commands = [];
4+
35
const rl = readline.createInterface({
46
input: process.stdin,
57
output: process.stdout,
@@ -8,3 +10,11 @@ const rl = readline.createInterface({
810
rl.question("$ ", (answer) => {
911
rl.close();
1012
});
13+
14+
const main = (rl) => {
15+
if (commands.includes(rl.question)) {
16+
console.log(`invalid_command: ${rl.question.split(" ")[0]} not found`);
17+
}
18+
};
19+
20+
main();

0 commit comments

Comments
 (0)