mirror of https://github.com/arendst/Tasmota.git
update git howto
parent
d82e860148
commit
9f6ecbac3d
|
@ -19,14 +19,25 @@ This wiki page is an attempt to document the Tasmota sensor API for sensor drive
|
|||
* Do not assume others will know immediately how to use your addition and know that you will need to write a Wiki for it in the end.
|
||||
|
||||
# Managing a Forked Branch
|
||||
- git checkout Tasmota development branch
|
||||
- git pull upstream development
|
||||
Now the local branch is synced to the Tasmota repo
|
||||
- git checkout -b <new_branch>
|
||||
- git push --set-upstream origin <new_branch>
|
||||
If you plan to submit a PR bigger than a simple change in one file, here is a short intro about how to do a clean PR.
|
||||
|
||||
- fork the Tasmota repository in Github
|
||||
- `git clone https://github.com/<github_user>/Sonoff-Tasmota.git` and work on your local copy
|
||||
- `git remote add upstream https://github.com/arendst/Sonoff-Tasmota.git`
|
||||
- `git checkout development`
|
||||
- `git checkout -b <temp_branch>` to create a working branch where you can push commits
|
||||
- `git push --set-upstream origin <temp_branch>`
|
||||
- work on your local version and push as many commits as you want
|
||||
|
||||
When you think it is ready to merge and submit a PR:
|
||||
- `git checkout development` to go back to the main branch
|
||||
- `git pull upstream development` to update all the latest changes
|
||||
- `git push` to update your fork
|
||||
- `git checkout -b <pr_branch>` to create a new branch for the final PR
|
||||
- `git push --set-upstream origin <pr_branch>`
|
||||
- Merge the edits but be sure to remove the history of your local commits
|
||||
- git merge --squash <your_initial_branch>
|
||||
- git commit -m "Message"
|
||||
- `git merge --squash <temp_branch>`
|
||||
- `git commit -m "Message"`
|
||||
|
||||
Now you have a clean single commit from which you can create the PR on the Tasmota Github.
|
||||
|
||||
|
|
Loading…
Reference in New Issue