pwd: Current working directory (eg : /home/erin/Documents )ls: List files in directoryclear: Clear the terminalcd: Change directory (eg cd ~/Documents , ~ means home directory )cd ..: Navigate to a directory behind ( /home/erin/hello ---> /home/erin )cd -: Navigate to previous directorymkdir Linus_hands_on: make a new folder called Linus_hands_ontouch my_file.txt: create a file my_file.txtnano my_file.txt: Open nano text editorcat my_file.txt: Display contet of the file in the terminalcp my_file.txt ~/file.txt: Create a copy of file in the home directory with name file.txtmkdir -p tutorials/RIG: make a folder tutorials followed by RIG within that foldermv my_file.txt tutorials/RIG/my_file.txt: move my_file.txt to tutorials/RIGmv my_file.txt linux.txt: rename my_file.txt to linux.txtcp linux.txt ~/Documents/Linus_hands_on/new.txt: create a copy of linux to Linus_hands_on with name newrm new.txt: Remove new.txt (rm can't be used for removing directory (or folder) can be used on for files)rmdir RIG/: Remove directory RIG (only work with empty directory)rm -r RIG: Remove directory RIG with content recursivelydate >> date.txt: Insert today's date to date.txt (eg Tue May 2022 ....)drwxrwxr-x:ls -l: Shows the permissions of the file (read wite access)ls | grep Documents: Search for file/folder with Documentsls | grep '*.pdf': find files of type pdffind -name download.png: find file download.pngecho "Hello World": Acts like print statement for terminalecho $SHELL: outputs /bin/bashman mkdir: shows manual for make directorynano command.sh: create a .sh file
inside command.sh
echo "Hello RIG"
chmod u+x command.sh: (add permission )Change permission for to be executable./command.sh: Execute the contents of the filechmod u-x command.sh: remove permission of the file
r w x : read wite execute 4 2 1 : (write) : 2 (read and write) : 4+2 = 6
chmod 764 command.sh: root user read write excute (sum 7) , currecnt user read and write , other user readps: Show process idps -aux | grep arduino: Show process id of arduinokill 15187: Kill arduino processsudo apt install htop: Install application called htop (can kill process , like task manager in windows)
Make changes in Windows drive
-
Unmount windows drive
-
sudo ntsfix /dev/sda5: Give edit access to windows directory -
sudo apt install tldrorsudo apt install neofetch -
tldr chmod: Give a small manual read for the command chmod -
dpkg -i google-chrome-stable.deb: Install a .deb file (wont check missing dependencies) -
sudo apt intsall google-chrome-stable.deb: ( Install any missing dependencies )