1. 6
  1.  

  2. 2

    Since I first saw github using the gh-pages branch for pages I found this to be some kind of antipattern. Sure, all branches should be different (otherwise what’s the point) but unless you’re doing a complete rewrite in the same repo there’s always some kind of evolution (at least in my head). To make this completeley absurd you could have a mono repo of every application in a different branch. Or maybe I’m just being weird…

    1. 1

      I guess it would make sense if master was on / and “branch” on branch/. So you have a release and previews.

    2. 1

      Unfortunately this is racy (WAR hazard). I use gl-pages for publishing internal docs of the project and it would be really handy to be able to publish these per-branch, however it will not work as expected exactly due to fact that it can race if there are 2 branches that want to publish the docs at the same time. There would need to be some kind of block or better - GL could allow to publish the pages only partially. That would allow such approach to work better.

      1. 1

        Yes, it might not be suitable for production with multiple contributors.

        My use case is to compare different branches during development. Worst thing that could happen if really two developers commit at the same time is that I would have to trigger the pipeline manually to update the page.