git checkout master # you can avoid this line if you are in master...
git subtree split --prefix dist -b gh-pages # create a local gh-pages branch containing the splitted output folder
git push -f origin gh-pages:gh-pages # force the push of the gh-pages branch to the remote gh-pages branch at origin
git branch -D gh-pages # delete the local gh-pages because you will need it: ref
This comment has been minimized.
This comment has been minimized.
Thanks mate! This was helpful :) |
This comment has been minimized.
This comment has been minimized.
Thanks! This was great. For anyone else stumbling on this, here are some pertinent doc links. Chances are you've seen this stuff, but |
This comment has been minimized.
This comment has been minimized.
Brilliant! Thanks. |
This comment has been minimized.
This comment has been minimized.
More concise approach:
|
This comment has been minimized.
This comment has been minimized.
OMG ! You saved my life ! I had tried for a long time ! Tks |
This comment has been minimized.
This comment has been minimized.
This is perfect. Thanks. |
This comment has been minimized.
This comment has been minimized.
This all requires that |
This comment has been minimized.
This comment has been minimized.
very nice, sir! |
This comment has been minimized.
This comment has been minimized.
I love this, but it would be nice if the local and remote branches weren't named the same in your example - I can never remember what order |
This comment has been minimized.
This comment has been minimized.
For those using fish shell:
|
This comment has been minimized.
Thank you good sir!