Linux Commands Cheat Sheet for Full Stack Developers

We've gathered a useful collection of code snippets libraries that can help you code faster and easier for helpful code snippets for Full Stack Developers (Linux). 

Source :- 
Author: Piotr Golon,, . Thank you for the share.

Cheat Sheets for Linux :-

Software Managing :-

dowloads latest software / packages list

$ sudo apt update

updates software based on previously downloaded list

$ sudo apt upgrade

installs specific software

$ sudo apt install package_name

find location of package files/binaries

$ whereis package_name

removes software but keeps configuration files

$ sudo apt remove package_name

removes software and configuration files

$ sudo apt purge package_name

shows all installed packages

$ apt list --installed

shows if a package is installed

$ apt list -installed package_name

searches installed packages based on a name

$ dpkg -l | grep -i put_your_search_name_here

shows available packages by pattern

$ apt search package-name

Exploring :-

home folder shortcut

~ (equals to /home/user_name/)

root folder


list all files in a current diectory (included hidden)

$ ls -al

current working directory path

$ pwd

change current directory to home

$ cd

change current directory to destination_path

$ cd destination_path (i.e cd ~)

change current directory to one level up

$ cd ..

history of inputed commands

$ history

manual for a command

$ man command_name (i.e. man cp)

System info :-

top current processes + resources usage summary

$ top

Linux version

$ lsb_release -a

System info

$ sudo dmidecode -t system

Kernel info

$ uname -a

current time and date

$ timedatectl

$ date

disks usage

$ df -h --total

file system partitions

$ sudo fdisk -l

shows verbose info

$ lsblk (Disks)

$ lshw (Hardware)

$ lscpu (CPU)

$ lsusb (USB)

alternative info based on DMI tables

$ sudo dmidecode -t (+ component name i.e. bios)

Files & folders :-

create a file

$ touch file_name.extension

create a folder

$ mkdir folder_name


$ cp ~/path_file_to_copy ~/destination (single file)

$ cp -R ~/path_to_folder ~/destination (single folder)

$ cp ~/*.extension ~/destination (all files with ext)


$ mv ~/file_or_directory_to move ~/destination


$ rm ~/file_to_remove.extension (single file)

$ rm -R ~/folder_to_remove (single folder)

find a file or a folder by name

$ find ~/destination --iname file_or_folder_name

show last lines of a file (usefull for large files i.e logs)

$ tail file_name.extension

Services :-

service commands

$ sudo service service_name status

$ sudo service service_name start

$ sudo service service_name stop

$ sudo service service_name restart

Post Author - Ravi Kumar (Linux)


Post a Comment

Iklan Atas Artikel

Iklan Tengah Artikel 1

Iklan Tengah Artikel 2

Iklan Bawah Artikel