Welcome to Software Development on Codidact!
Will you help us build our independent community of developers helping developers? We're small and trying to grow. We welcome questions about all aspects of software development, from design to code to QA and more. Got questions? Got answers? Got code you'd like someone to review? Please join us.
Post History
I just realized that I started writing code for what was going to become a second independent feature on the branch I was already working on. --A--B--C main \ `Q--R--S--X--Y-...
#1: Initial revision
How do I split a feature branch into two?
I just realized that I started writing code for what was going to become a second independent feature on the branch I was already working on.
```text
--A--B--C main
\
`Q--R--S--X--Y--Z feature-1
```
How do I split my work into two different branches diverging from `main`?
```text
--A--B--C main
|\
| `Q--R--S feature-1
\
`X--Y--Z feature-2
```
My question is different from [this one][1] because in that question, upstream already merged `feature-1` into their `main`.
[1]: https://software.codidact.com/posts/294731
