ci: fix workflow definitions

1. Currently builds are not happening on master (very bad)
2. goreleaser builds are not working (very annoying)

Problem 1 was created by an "if" constraint being in the wrong place on
the start job for the test workflow. Because the test job depends on the
start job, the start job must run. Therefore we add a condition to every
step in the start job instead... which is easy using CUE.

Fix both of these.

Fixes #671

Change-Id: I0a36a44f35733dfd866f01dc608e35efcd1c5eab
Reviewed-on: https://cue-review.googlesource.com/c/cue/+/8404
Reviewed-by: Paul Jolly <paul@myitcv.org.uk>
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
index 912e2ec..01f7594 100644
--- a/.github/workflows/release.yml
+++ b/.github/workflows/release.yml
@@ -19,7 +19,7 @@
     - name: Run GoReleaser
       env:
         GITHUB_TOKEN: ${{ secrets.ACTIONS_GITHUB_TOKEN }}
-      uses: docker://goreleaser/goreleaser:latest
+      uses: docker://goreleaser/goreleaser:v0.110.0
       with:
         args: release --rm-dist
   docker:
diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml
index 0049b49..b43127f 100644
--- a/.github/workflows/test.yml
+++ b/.github/workflows/test.yml
@@ -13,11 +13,12 @@
     defaults:
       run:
         shell: bash
-    if: ${{ startsWith(github.ref, 'refs/heads/ci/') }}
     steps:
-    - name: Write the gitcookies file
+    - if: ${{ startsWith(github.ref, 'refs/heads/ci/') }}
+      name: Write the gitcookies file
       run: echo "${{ secrets.gerritCookie }}" > ~/.gitcookies
-    - name: Update Gerrit CL message with starting message
+    - if: ${{ startsWith(github.ref, 'refs/heads/ci/') }}
+      name: Update Gerrit CL message with starting message
       run: 'curl -f -s -H "Content-Type: application/json" --request POST --data ''{"message":"Started
         the build... see progress at ${{ github.event.repository.html_url }}/actions/runs/${{
         github.run_id }}"}'' -b ~/.gitcookies https://cue-review.googlesource.com/a/changes/$(basename
diff --git a/internal/ci/workflows.cue b/internal/ci/workflows.cue
index 6769120..06ccaf1 100644
--- a/internal/ci/workflows.cue
+++ b/internal/ci/workflows.cue
@@ -43,7 +43,7 @@
 	jobs: {
 		start: {
 			"runs-on": _#linuxMachine
-			if:        "${{ \(_#isCLCITestBranch) }}"
+			steps: [...(_ & {if: "${{ \(_#isCLCITestBranch) }}"})]
 			steps: [
 				_#writeCookiesFile,
 				_#startCLBuild,
@@ -200,7 +200,7 @@
 			}, {
 				name: "Run GoReleaser"
 				env: GITHUB_TOKEN: "${{ secrets.ACTIONS_GITHUB_TOKEN }}"
-				uses: "docker://goreleaser/goreleaser:latest"
+				uses: "docker://goreleaser/goreleaser:v0.110.0"
 				with: args: "release --rm-dist"
 			}]
 		}