Skip to content

pyastrolab/basic-git-guide

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🧰 Basic Git Guide

This guide covers the essential Git commands to get started with this repository. Refer: https://basic-git-guide.vercel.app and git_cheat_sheet.pdf

📦 Clone the Repository

git clone https://github.com/your-username/your-repo-name.git
cd your-repo-name

🔧 Set Up Git (if you haven't already)

git config --global user.name "Your Name"
git config --global user.email "[email protected]"

🌿 Create a New Branch

git checkout -b your-feature-branch

Use a descriptive name like fix/readme-typo or feature/user-login.


📝 Make Changes and Commit

git add .
git commit -m "Your meaningful commit message"

🔄 Pull Latest Changes

Make sure your branch is up to date before pushing:

git pull origin main  # or 'master' if your repo uses that

🚀 Push Your Changes

git push origin your-feature-branch

📥 Create a Pull Request

  1. Go to the GitHub repository in your browser.
  2. Click "Compare & pull request".
  3. Add a title and description for your PR.
  4. Submit the pull request.

🧹 Optional: Delete Branch After Merge

git branch -d your-feature-branch        # delete local
git push origin --delete your-feature-branch  # delete remote

About

A Short Guide to Understand the Working of Git and Github.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published