workflow/docs: Fix deployments
authorDan Nicholson <dbn@endlessos.org>
Sun, 15 Sep 2024 19:59:36 +0000 (13:59 -0600)
committerDan Nicholson <dbn@endlessos.org>
Sun, 15 Sep 2024 20:01:19 +0000 (14:01 -0600)
commit8d1373bdd741e1bc7ced089b527d3e3aa2244116
treeafe6eb0d9277f0ed5da88972215c1cf596981742
parent558f260554296181ec47bb330bef16f27780e117
workflow/docs: Fix deployments

A couple fixes to make PRs and non-PRs work correctly:

* In a conditional expression, `true` or `false` are returned unless you
  terminate both sides in a ternary. That was causing 2 strings to be
  suffixed with `false` instead of an empty string.
* For a PR, we do actually want to cancel in progress runs since there's
  no danger of breaking an in progress deployment.
* For PRs, just use the same `github-pages-pr` name for the artifact.
  The important part is that it's not called `github-pages` where an in
  progress deployment could pick it up. Otherwise it can use the same
  name all the time.
.github/workflows/docs.yml