Linux Basic Guide (Ubuntu/Kali)

Commands, concepts, and programs tutorial

Installing WSL

dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart

After restart:

wsl --install

After restart, go to Microsoft Store, pick whatever distribution you like & install it.

General knowledge

Working Directory (WD)

Root Permissions

Files/Directories

Editing text files

Running executables

About $PATH

Running

Multiple commands

File Input/Output pipe redirection

Environment Variables

The system has some variables with assigned values, so programs can use it

Processes management

File Permissions

When doing ls -la, here is an expected output:

drwxrwxrwx root root somedir
lrwxr-xr-- root root somelnk
-rw-rw-r-- user user somefile

For more, check this page

About shells

Shell execuatables

Example

#!/bin/bash

g++ --version > script_temp.txt
head -n 1 script_temp.txt
rm script_temp.txt

This script will show you the first line of g++ --version output

Example 2

Helping Programs

Package Manager

Different Systems Package Manager

apt