mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-20 12:54:11 +08:00
Add "Delete a branch" and simplified the language a bit.
@ -37,16 +37,22 @@ USE_KINETO=0 BUILD_CAFFE2=0 USE_DISTRIBUTED=0 USE_NCCL=0 BUILD_TEST=0 USE_XNNPAC
|
||||
|
||||
The head of the pytorch/pytorch master branch may have test failures ([see here for the current state](https://hud.pytorch.org/)). When developing PyTorch, instead of branching off of `master`, you can branch off of `viable/strict`. `viable/strict` is a branch that lags behind master and guarantees that all PyTorch tests are passing on the branch. Basing your work off of `viable/strict` gives you confidence that any test failures are actually your code's fault.
|
||||
|
||||
Some quick git tips:
|
||||
Some quick git tips on maintaining feature branches:
|
||||
```
|
||||
# Creating a new feature branch off of viable/strict
|
||||
# These tips assume upstream points to pytorch/pytorch. (Some people develop with origin pointing to pytorch/pytorch.)
|
||||
|
||||
# Create a new branch from upstream/viable/strict
|
||||
git fetch upstream viable/strict
|
||||
git checkout -b my_new_feature upstream/viable/strict
|
||||
git push -u origin my_new_feature
|
||||
|
||||
# Rebasing your work to appear on top of viable/strict, assuming upstream points to pytorch/pytorch.
|
||||
# (Some people develop with origin pointing to pytorch/pytorch)
|
||||
# Rebase work on a branch to appear on top of viable/strict
|
||||
git pull --rebase upstream viable/strict
|
||||
|
||||
# Delete a branch
|
||||
git checkout main
|
||||
git branch -D my_new_feature
|
||||
git push --delete origin my_new_feature
|
||||
```
|
||||
### For more details
|
||||
|
||||
|
Reference in New Issue
Block a user