Making My Own CLI(Command Line Interface) Using CMD : <p>In the previous accepted reply I found the following code. <a href="https://codereview.stackexchange.com/questions/41121/making-a-bat-batch-command-line-interface#new-answer?s=0857a55f8b4e43c1a1d4b13236169370">source</a>: <a href="https://codereview.stackexchange.com/questions/41121/making-a-bat-batch-command-line-interface#new-answer?s=0857a55f8b4e43c1a1d4b13236169370">https://codereview.stackexchange.com/questions/41121/making-a-bat-batch-command-line-interface#new-answer?s=0857a55f8b4e43c1a1d4b13236169370</a></p>

<h2>Title: Making a .bat batch command-line interface</h2>

<pre><code>:: Define all valid commands: make sure there is a space between each command
:: and also one at beginning and end
set "commands= something echo exit "

:input.get

:: Clear the existing value in case user hits &lt;Enter&gt; without entering anything
set "input="

:: Get the next command
set /p "input=COMMAND\&gt;"

:: Parse command into command and arguments.
for /f "tokens=1* delims= " %%A in ("!input!") do (

  REM check if command is valid (not case sensitive) and act accordingly
  if "!commands: %%A =!" equ "!commands!" (
    echo Invalid command: %%A
  ) else if /i %%A equ exit (
    exit /b
  ) else (
    call :%%A %%B
  )
)
echo(
goto input.get


:something
echo Doing something with Arg1=[%1] and Arg2=[%2]
exit /b

:echo
echo(%*
exit /b
</code></pre>

<p>If I want to add one more command how to do that?
like if user write 'pop' then he/she wile get the reply like bellow:</p>

<pre><code>You wrote pop
</code></pre>

<p>Now how can I this by editing this.</p>
