βοΈHere's a simple cheat sheet for Linux, Git, and GitHub:
π§ Linux Commands:
Command | Purpose | Example Usage |
ls | List files and directories | ls -l (long format) π |
cd | Change directory | cd Documents π |
pwd | Print working directory | pwd ποΈ |
mkdir | Create a new directory | mkdir my_folder π |
rm | Remove files or directories | rm file.txt ποΈ |
cp | Copy files or directories | cp file.txt backup/ π¦ |
mv | Move or rename files | mv old.txt new.txt π |
chmod | Change file permissions | chmod 755 script.sh π |
grep | Search for patterns in files | grep "error" log.txt π |
top | Monitor system processes | top -n 1 (one-time snapshot) π |
π Git Commands:
Command | Purpose | Example Usage |
git init | Initialize a new Git repository | git init π± |
git clone | Clone a remote repository | git clone <URL> π₯ |
git add | Stage changes for commit | git add file.txt β |
git commit | Commit changes with a message | git commit -m "Fix bug" π‘ |
git status | View the status of files | git status π |
git log | Display commit history | git log --oneline π |
git branch | Manage branches | git branch feature πΏ |
git merge | Merge branches | git merge dev π€ |
git pull | Fetch changes from a remote repository | git pull origin main π |
git push | Push local changes to a remote repository | git push origin feature π |
πΌ GitHub Commands:
Command | Purpose | Example Usage |
git remote add origin <URL> | Link-local repo to a remote GitHub repo | git remote add origin <URL> π |
git push -u origin <branch> | Push changes to GitHub | git push -u origin main π |
git pull origin <branch> | Pull changes from GitHub | git pull origin feature π |
git checkout -b <branch> | Create and switch to a new branch | git checkout -b feature π± |
git fork | Fork a repository on GitHub | git fork π΄ |
git pull-request | Create a pull request | git pull-request π₯ |
π Feel free to use this cheat sheet as a quick reference! π
Happy Coding :) πβ‘
β Feel free to reach out if you have any questions. I'm delighted to help! π
π€ Let's Connect..!
π LinkedIn
π Twitter
π GitHub
βοΈβοΈβοΈβοΈβοΈβοΈβοΈβοΈβοΈβοΈβοΈβοΈβοΈβοΈβοΈβοΈβοΈβοΈβοΈβοΈβοΈβοΈβοΈβοΈβοΈβοΈβοΈβοΈβοΈ
Β