English terminal guide: Fix typo, add rm example, and add caution note. (#24768)
* Add missing command and iTerm2 section * Fix typo, add rm example and caution note * Revert changespull/24134/head^2
parent
97616fe6fa
commit
0577e81cf5
|
@ -8,6 +8,7 @@ title: Mac OS Terminal
|
|||
Most of the time users interact through a Graphical User Interface to interact with the computer. You use the mouse to point and click to open, move, or create new files or open applications. But, you can also use the Terminal Application to interact with your machine through written commands. When you use the terminal, it allows you to dig deeper and customize in a way not possible through the GUI.
|
||||
|
||||
### Opening the Terminal and Navigating Directories
|
||||
|
||||
Your terminal exists in the Applications directory. Open your Terminal app. You should see a prompt in the terminal window. It should have the computer's name (ABC's Macbook), followed by the User name (ABC), and then a '$'. If you are in the root directory, the last character will be a '#'.
|
||||
|
||||
To see what directory you are working in, just type the command:
|
||||
|
@ -53,7 +54,7 @@ Some of the aforementioned commands aren't clear without examples. Below are a f
|
|||
#### Making a Directory
|
||||
|
||||
```
|
||||
mkdir folder_name
|
||||
mkdir <your_new_folder_name>
|
||||
```
|
||||
|
||||
#### Making a File
|
||||
|
@ -80,10 +81,16 @@ cp ~/Desktop/test.txt ~/Documents
|
|||
|
||||
Use the following syntax to delete a file.
|
||||
|
||||
**rm <path_to_file>**
|
||||
|
||||
For example, if you want to delete the test file you created above, your command line should like like this:
|
||||
|
||||
```
|
||||
rm <path_to_file>
|
||||
rm test.txt
|
||||
```
|
||||
|
||||
**Note:** Removing files this way is permanent, deleted files will skip the trash completely, leaving you with few options for file recovery. Always be careful when using this command and back up your machine frequently!
|
||||
|
||||
#### Detect which process is using the port you want to use
|
||||
```
|
||||
lsof -i :<port>
|
||||
|
|
|
@ -59,4 +59,4 @@ cp ~/Desktop/test.txt ~/Documents
|
|||
|
||||
Usa la siguiente sintaxis para borrar un archivo
|
||||
|
||||
**rm _#PATH_ TO _FILE_**
|
||||
**rm _#PATH_ TO _FILE_**
|
||||
|
|
Loading…
Reference in New Issue