Hi πthere,
Now we are on the Day 11 task
(Linux and Github Cheatsheet)
Checkout the below link for Day 11 task:
https://github.com/LondheShubham153/90DaysOfDevOps/blob/master/2023/day12/tasks.md
Here is a basic Git cheat sheet for common Git commands:
Initialize a new Git repository:
git init
Check the status of your repository:
git status
Add changes to the staging area:
git add <file>
orgit add.
(to add all changes)Commit changes:
git commit -m "Commit message"
Push changes to a remote repository:
git push <remote> <branch>
Pull changes from a remote repository:
git pull <remote> <branch>
Create a new branch:
git branch <branch name>
Switch to a different branch:
git checkout <branch name>
Merge branches:
git merge <branch to merge>
View commit history:
git log
Undo local changes:
git checkout -- <file>
Revert to a previous commit:
git revert <commit hash>
Clone a remote repository:
git clone <repository URL>
Reset to a specific commit:
git reset <commit hash>
Delete a branch:
git branch -d <branch name>
This is a basic list of Git commands.
Linux Cheat Sheet
Here is a basic Linux cheatsheet for common Linux commands:
ls β The most frequently used command in Linux to list directories
pwd β Print working directory command in Linux
cd β Linux command to navigate through directories
mkdir β Command used to create directories in Linux
mv β Move or rename files in Linux
cp β Similar usage as mv but for copying files in Linux
rm β Delete files or directories
touch β Create blank/empty files
ln β Create symbolic links (shortcuts) to other files
cat β Display file contents on the terminal
clear β Clear the terminal display
echo β Print any text that follows the command
less β Linux command to display paged outputs in the terminal
man β Access manual pages for all Linux commands
name β Linux command to get basic information about the OS
whoami β Get the active username
tar β Command to extract and compress files in Linux
grep β Search for a string within an output.
head β Return the specified number of lines from the top
tail β Return the specified number of lines from the bottom
diff β Find the difference between two files
CMP β Allows you to check if two files are identical
comm β Combines the functionality of diff and cmp
sort β Linux command to sort the content of a file while outputting
export β Export environment variables in Linux.
zip β Zip files in Linux
unzip β Unzip files in Linux
ssh β Secure Shell command in Linux
service β Linux command to start and stop services
ps β Display active processes
kill and kill all β Kill active processes by process ID or name
df β Display disk filesystem information
mount β Mount file systems in Linux
chmod β command to change file permissions
chown β Command for granting ownership of files or folders
ifconfig β Display network interfaces and IP addresses
traceroute β Trace all the network hops to reach the destination
wget β Direct download files from the internet
apt, Pacman, yum, rpm β Package managers depending on the distro
sudo β Command to escalate privileges in Linux
ls -l - list
This is a basic list of linux commands.
Please, feel free to drop any questions in the comments below. I would be happy to answer them.
If you find this post helpfulππ, please follow and click the heartβ€β€ button below to show your support.
_ Thank you for reading
_sandhya kumari