Skip to main content
Stack Overflow
  1. About
  2. For Teams

Return to Answer

Post Made Community Wiki by blackgreen
Commonmark migration
Source Link

Deleting Branches

Let's assume our work on branch "contact-form" is done and we've already integrated it into "master". Since we don't need it anymore, we can delete it (locally):

$ git branch -d contact-form

And for deleting the remote branch:

git push origin --delete contact-form

Deleting Branches

Let's assume our work on branch "contact-form" is done and we've already integrated it into "master". Since we don't need it anymore, we can delete it (locally):

$ git branch -d contact-form

And for deleting the remote branch:

git push origin --delete contact-form

Deleting Branches

Let's assume our work on branch "contact-form" is done and we've already integrated it into "master". Since we don't need it anymore, we can delete it (locally):

$ git branch -d contact-form

And for deleting the remote branch:

git push origin --delete contact-form
deleted 271 characters in body
Source Link
Ulysses Alves
  • 2.5k
  • 3
  • 26
  • 38

Deleting Branches

Let's assume our work on branch "contact-form" is done and we've already integrated it into "master". Since we don't need it anymore, we can delete it (locally):

$ git branch -d contact-form

Tidy as we are, we also delete the remote branch by simply adding the "-r" flag:

$ git branch -dr origin/contact-form

As Geuis has said in the comments, this will only delete the remote branch tracking reference. So, you need to also run the following command to finish the branch deleting procedure: And for deleting the remote branch:

git push origin --delete contact-form

Deleting Branches

Let's assume our work on branch "contact-form" is done and we've already integrated it into "master". Since we don't need it anymore, we can delete it:

$ git branch -d contact-form

Tidy as we are, we also delete the remote branch by simply adding the "-r" flag:

$ git branch -dr origin/contact-form

As Geuis has said in the comments, this will only delete the remote branch tracking reference. So, you need to also run the following command to finish the branch deleting procedure:

git push origin --delete contact-form

Deleting Branches

Let's assume our work on branch "contact-form" is done and we've already integrated it into "master". Since we don't need it anymore, we can delete it (locally):

$ git branch -d contact-form

And for deleting the remote branch:

git push origin --delete contact-form
added 241 characters in body
Source Link
Ulysses Alves
  • 2.5k
  • 3
  • 26
  • 38

Deleting Branches

Let's assume our work on branch "contact-form" is done and we've already integrated it into "master". Since we don't need it anymore, we can delete it:

$ git branch -d contact-form

Tidy as we are, we also delete the remote branch by simply adding the "-r" flag:

$ git branch -dr origin/contact-form

As Geuis has said in the comments, this will only delete the remote branch tracking reference. So, you need to also run the following command to finish the branch deleting procedure:

git push origin --delete contact-form

Deleting Branches

Let's assume our work on branch "contact-form" is done and we've already integrated it into "master". Since we don't need it anymore, we can delete it:

$ git branch -d contact-form

Tidy as we are, we also delete the remote branch by simply adding the "-r" flag:

$ git branch -dr origin/contact-form

Deleting Branches

Let's assume our work on branch "contact-form" is done and we've already integrated it into "master". Since we don't need it anymore, we can delete it:

$ git branch -d contact-form

Tidy as we are, we also delete the remote branch by simply adding the "-r" flag:

$ git branch -dr origin/contact-form

As Geuis has said in the comments, this will only delete the remote branch tracking reference. So, you need to also run the following command to finish the branch deleting procedure:

git push origin --delete contact-form
added 7 characters in body
Source Link
Ulysses Alves
  • 2.5k
  • 3
  • 26
  • 38
Loading
Source Link
Ulysses Alves
  • 2.5k
  • 3
  • 26
  • 38
Loading

AltStyle によって変換されたページ (->オリジナル) /