Linux
Linux is a free and open-source operating system. There are many different versions of Linux, called distributions. Linux is a very popular operating system for servers, mobile phones (Android) and computer enthusiasts.
Linux commands
Linux commandsLinux commands are very useful when you are working with the Linux operating system. There are many different commands, but you only need a handful of these to do most things, like navigating directories, modifying files and get information about the system.
command | description | example |
---|---|---|
ls | List files and directories in the current directory | ls /home |
cd | Change the current directory | cd /home |
mv | Move a file to a different location | mv old/cat.png new/cat.png |
rm | Remove a file or directory | rm file.txt |
cp | Copy a file to a different location | cp first/cat.png second/cat.png |
nano | Edit the contents of a text file | nano script.cpp |
sudo | Execute a function as super user | sudo nano script.cpp |
mkdir | Create a new directory | mkdir amazing-directory |
rmdir | Remove a directory | rmdir amazing-directory |
Linux directories
Linux directoriesLinux has a different directory structure than Windows or macOS. The most important directory is the root directory, denoted with a slash "/". All directories and files are located under this directory.
Linux permissions
Linux permissionsLinux has a comprehensive permission system to ensure that the computer is secure. Each file and directory has three groups of permissions: owner, group and all users. Each of these groups has three types of permissions: read write and execute. Using the right permissions is a necessity for servers and other devices connected to the internet.