Problem
In the Windows system, type a random cmd into the terminal will return an "undefined" error as following:
C:\Documents>abcd
'abcd' is not recognized as an internal or external command,
operable program or batch file.
What I want is when in this case, a script is run with passing the undefined cmd as an argument. Then in the script, I can define how to handle it.
Why I have this problem
Since I installed WSL, I want to pass all undefined cmd into WSL so that all the Linux cmd can be directly recognized in the batch terminal. Recently my workaround is to define lots of batch scripts that can be recognized by windows-cmd pass it. This, however, looks wordy and less smart.