The workaround is to create a new text document in the C:\Windows\System32 directory with the following file contents:
@echo off
Dir
Save as "Ls.bat" type for all files, coded ANSI
Either dir or LS can be used
Often the user switching between Windows and Linux may face a problem-some of the commands are different, sometimes easy to confuse, such as Windows listed in the directory of files and folders with the command "dir", but under Linux is "LS".
To solve this problem, under Linux you can use "Alias" to create aliases for using commands under Windows, such as alias dir= ' ls ', and then you can use DIR instead of the LS command.
But no "alias" command was found under Windows. But we can "create aliases" with a very simple batch script. The script reads as follows:
@echo off
Dir
Save the script as "Ls.bat" and store it in
"C:\WINDOWS\system32\" (of course you can also store the other path variable to the directory), you can use the "ls" command under WINDOWS.
"ls" command in Windows