=====Basic Terminal Usage===== At first the command line might seem daunting but you can use these quick tips to speed things up a little. You'll soon be able to navigate the terminal like a pro. ====Terminal Fundamentals==== To open a terminal, press ctrl+alt+t Tab completion: If you type the first few characters of the thing you want and then press your tab key, the terminal will show a list of all possible completions which begin with those characters. If you hit tab while on the first word of a command, it will show possible commands; otherwise, it will show files and directories. ====Useful Commands==== Things within angle brackets should be replaced with the file or directory you're working with; the angle brackets themselves shouldn't actually be typed. ^ Command ^ Command name ^ Usage | | ls | List | Shows the contents of the current directory | | ls | | Shows the contents of (this applies to the other uses of ls, too) | | ls -a | | List all files in the current directory, even hidden ones | | ls -l | | List all files along with their size, owner, and other information | | ls -lh | | Same as above, but lists sizes in "human-readable" format (184M instead of 191901696) | | cd | Change directory | Switch to the directory specified | | cd ../ | | Go up one directory (this works more than once; cd ../../ goes up two directories, etc.) | | cp | Copy | Copy file or directory from to . This will not warn you about overwriting files, see cp -i | | cp -i | | As cp, but will ask you before overwritting files; you should this instead of cp | | mv | Move | Move file or directory from to . Also used to rename files: you move the file from the old name to the new one. This will not warn you about overwriting files, see mv -i | | mv -i | | As mv, but will ask you before overwritting files; you should this instead of mv | | rm | Remove | Removes (in other words, deletes) . Since this will definitely wipe out files, use the version below | | rm -i | | As rm, but asks for confirmation | | rm -r | | Removes and everything contained therein, including other directories. Use wisely. | | mkdir | Make directory | Creates a new directory called | | mkdir -p | | Used to, e.g., create some/new/directory even if the some/ and some/new/ directories don't already exist; it will create any new directories as necessary | | ps -Af | Processes | See all running processes and which user is running them | | lp | Print | Print file on default printer | Because of the potential risk of overwriting files with cp, mv, and rm, many experienced users recommend changing the actions of these commands using the ''alias'' command; see the [[howto:intermediateterminalusage| Intermediate]] page for details. ====Console Copy and Paste==== To copy text from the terminal just highlight the text that you want to copy; you don't need to press any special keys. To paste, click on the terminal window and use shift+ins or press both mouse keys at the same time (middle mouse key) and the highlighted text should appear in the terminal. If you want to use traditional copy and paste (aka gui paste) you should use konsole instead; simply type ''konsole'' in the terminal to start a console with paste support. ====Additional Information==== For further useful commands and a discussion of the Linux directory structure, please read [[howto:intermediateterminalusage| Intermediate Terminal Usage]].