Terminal Git vs Terminal Node vs Windows Terminal
I'm having some difficulty understanding the need to have so many terminals installed on the computer when I need to use git or node. js. What are the differences between terminals, what can one do and the other not? For example: I wanted to check if I had Node. js installed on my Windows 10, so I did
which nodein the Windows terminal and without success, I realize that this command is not implemented in this terminal and I have to use another one ( Git gave me the installation path), but how to know which one to use for each task if in the article/tutorial is not specified?
Quite simply, the "terminals" (as they are called) or CLICKsCOmmand Line Interface) are software that allows you to run commands, such commands can be other compiled software or simple scripts written specifically for the CLI "x" and interpreted also by it.
Why so many?
There is no real need to have everyone, the main difference of each is how it is configured and written, which ends up implying the commands that it will manage.
The Node terminal, for example, already comes with the command
nodeavailable, different from GitBash, which comes with commands
gitavailable, while the default Windows terminal has none of them.
Where do these commands come from?
Each terminal will search for compatible commands in the places where it is configured to search. The Windows CMD, for example, will consume the environment variable
PATH, indexing all compatible commands when opening the terminal and every time you give a command, the CMD will try to use any of these commands and if it has found, it will run it.
These "commands" can be files
.exeand in the CMD
.bat. Terminal on Mac can run files
.batand so on.
What's the best?
Goes from taste and need, I use enough (in Windows environment) emulator http://cmder.net/ , the CLI http://gitforwindows.org/ and the CLI CMD.
You can still add the program you want (since it is compatible) in any CLI, to add the
nodein CMD, for example, you just need to include the file path
PATHWindows. And this means you can choose and use CLI whatever you want.