Hello, folks!, I'm P Sathya Narayan
- Go to https://git-scm.com
- After Successfully installing with all Recommended Settings
- Open your CMD/Terminal
- Type
git --version
- Configure your Git
git config ––global user.name “your github_username”
git config ––global user.email “email_address”
- Now Create a Repository in your Github
- Copy the repo url
- Now there are two ways
- One by cloning this repo
git init
git commit -m "first commit"
git branch -M main
git remote add origin https://github.com/psathyanarayan/testtt.git
git push -u origin main
- Or by coding then pushing to this repo
git remote add origin https://github.com/psathyanarayan/testtt.git
git branch -M main
git push -u origin main
- This creates and changes to the new branch new
git branch new
git checkout new
- I commited 3 chnages to my file
git log --oneline
- If I need to know what is in the 2nd commit of Hello.py
git show 66874b6:Hello.py
- If I need to revert to this change then
git checkout 66874b6 Hello.py
- First fork this repo
- Clone this Repo with the below command from your repository
git clone your forked repo url with no quotes
- Note Before cloning please install git
- After cloning Open the folder then edit the Hello.py file by adding the below command
print("Your Name Here")
- Then add this to git by
git add .
- Then Commit it with a message
git commit -m "Added Your Name"
- If you have configed git then
git push -u origin main
- After you pushed to your forked repo You need to create a Pull Request
- Follow the instructions
- Click on Pull request after you commited as shown
- Click on New Pull request
- Click on Create Pull request as shown
- Click on Create
- Wow Congratssss
- You did great