0% found this document useful (0 votes)
5 views2 pages

Git Commands

The document provides a series of Git commands and steps for managing the Avinash project, including cloning the repository, checking out branches, and resolving conflicts. It outlines how to commit changes, pull updates from the master branch, and handle ignored files. Additionally, it includes instructions for accessing specific files and switching between branches in the project.

Uploaded by

Bl Gocher
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views2 pages

Git Commands

The document provides a series of Git commands and steps for managing the Avinash project, including cloning the repository, checking out branches, and resolving conflicts. It outlines how to commit changes, pull updates from the master branch, and handle ignored files. Additionally, it includes instructions for accessing specific files and switching between branches in the project.

Uploaded by

Bl Gocher
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 2

=============================================================== GIT NOTES: 09-01-

2025 ==========================

--------------------------------------------------- AVINASH PROJECT


---------------------------------------------
steps:
- open cmd inside proj folder
- git status

Change branch- master : git checkout master


to get master code : git pull

---------------------------
first created workspace
then
cloned project : git clone https://github.com/theavi/barbershop.git
check git branch :git branch
if not master then
git checkout master

to enter inside proeject: cd barbershop

--------------------------------------------------- OTHER
-------------------------------------------------------

to ignor target/* : git rm -r --cached target/*

For local repo commit : git commit -m "BARBAR-05 get district page intitiated"
git add .
git commit -m "Conflict resolved"
git pull

git push -u origin master

--------------------

to get only one file direct from master : git checkout origin/master
src/main/java/com/barbershop/controller/CountryController.java
create new branch and checkout code in that : git checkout -b BARBER-05 master

TO get daily avinash branch code : git checkout BARBER-03


{how to change again for my local}

-----------------

git rm -rf --cached .idea


git add .
git commit -m "Added excluded idea file"
git push
if we dont have master clone then
git checkout master
git pull

------------NOTE: HOW TO RESOLVE Conflict -------------


CLICK ON CONFICT WARNING ON TOP
- resolve conflict
- there is 3 schreen [1-left] our own page [2 middile- our local repo page] [3-
remote repo master page]
resovle from schreen page to middile page if we take changes from master repo to
local repo click on arrow.

-------------------------------------------------------

https://getbootstrap.com/docs/4.0/components/jumbotron/

================= how to get other or avinash branch code =======


create new folder
clone project : git clone https://github.com/theavi/barbershop.git

change dir as enter inside project in cmd : cd barbershop


then
check out that person branch : git checkout BARBER-03
now open new intellij and take project

You might also like