-
$ git branch -a
-
$ git remote add [REMOTE BRANCH VARIABLE] [REMOTE BRANCH URL] $ git remote add origin [URL]
P.S.
REMOTE BRANCH VARIABLE
is the remote branch variable you give like,origin
-
$ git remote remove [REMOTE BRANCH NAME] $ git remote remove origin
-
$ git push [REMOTE BRANCH VARIABLE] -d [REMOTE BRANCH NAME] $ git push origin -d fix-bugs
P.S.
-d
flag meansdelete
|fix-bugs
branch would be deleted. -
$ git checkout --track origin/<REMOTE_BRANCH_NAME>
-
-
Clone the master branch:
$ git clone [URL]
-
Inspect the contributors to the repo:
$ git log
-
Create a new git branch for your developments
$ git switch -c [YOUR BRANCH NAME] $ git switch -c my-branch
-
Stage your changes
$ git add .
-
Commit changes
$ git commit -m "[COMMIT MESSAGE]" $ git commit -m "fixed bug in pipeline"
P.S.
give meaningful messages to commits
-
Push your branch to remote repo
$ git push [REMOTE BRANCH VARIABLE] [YOUR BRANCH NAME] $ git push origin my-branch
P.S.
REMOTE BRANCH VARIABLE
is the remote branch variable you give like,origin
-
-
-
Commit changes
$ git commit -m "[COMMIT MESSAGE]"
-
Pull and rebase changes from main
git pull origin main --rebase
-
Push
git push origin [BRANCH NAME]
-
Last active
April 13, 2023 12:29
-
-
Save Ifejeremiah/f042a9c4c451d8cc9ab447d751d612d1 to your computer and use it in GitHub Desktop.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment