# Coming from CMD.EXE This table was last updated for Nu 0.67.0. | CMD.EXE | Nu | Task | | ------------------------------------ | ----------------------------------------------------------------------------------- | --------------------------------------------------------------------- | | `ASSOC` | | Displays or modifies file extension associations | | `BREAK` | | Trigger debugger breakpoint | | `CALL ` | `` | Run a batch program | | | `nu ` | Run a nu script in a fresh context | | | `source ` | Run a nu script in this context | | | `use ` | Run a nu script as a module | | `CD` or `CHDIR` | `$env.PWD` | Get the present working directory | | `CD ` | `cd ` | Change the current directory | | `CD /D ` | `cd ` | Change the current directory | | `CLS` | `clear` | Clear the screen | | `COLOR` | | Set the console default foreground/background colors | | | `ansi {flags} (code)` | Output ANSI codes to change color | | `COPY ` | `cp ` | Copy files | | `COPY + ` | `[, ] \| each { open --raw } \| str join \| save --raw ` | Append multiple files into one | | `DATE /T` | `date now` | Get the current date | | `DATE` | | Set the date | | `DEL ` or `ERASE ` | `rm ` | Delete files | | `DIR` | `ls` | List files in the current directory | | `ECHO ` | `print ` | Print the given values to stdout | | `ECHO ON` | | Echo executed commands to stdout | | `ENDLOCAL` | `export-env` | Change env in the caller | | `EXIT` | `exit` | Close the prompt or script | | `FOR % IN () DO ` | `for $ in { }` | Run a command for each item in a set | | `FTYPE` | | Displays or modifies file types used in file extension associations | | `GOTO` | | Jump to a label | | `IF ERRORLEVEL ` | `if $env.LAST_EXIT_CODE >= { }` | Run a command if the last command returned an error code >= specified | | `IF EQU ` | `if == { }` | Run a command if strings match | | `IF EXIST ` | | Run a command if the file exists | | `IF DEFINED ` | | Run a command if the variable is defined | | `MD` or `MKDIR` | `mkdir` | Create directories | | `MKLINK` | | Create symbolic links | | `MOVE` | `mv` | Move files | | `PATH` | `$env.Path` | Display the current path variable | | `PATH ;%PATH%` | `$env.Path = ($env.Path \| prepend `) | Edit the path variable | | `PATH %PATH%;` | `$env.Path = ($env.Path \| prepend `) | Edit the path variable | | `PAUSE` | `input "Press any key to continue . . ."` | Pause script execution | | `PROMPT