Skip to content

(human) can now show diff for current session state #37

(human) can now show diff for current session state

(human) can now show diff for current session state #37

Workflow file for this run

name: release (docs)

Check failure on line 1 in .github/workflows/release-docs.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/release-docs.yml

Invalid workflow file

(Line: 29, Col: 13): Unexpected symbol: 'hofstadter-io/hof'. Located at position 22 within expression: github.repository != hofstadter-io/hof
"on":
push:
tags:
- docs-**
workflow_dispatch:
inputs:
deploy:
description: where to deploy
required: true
default: next
type: choice
options:
- next
- prod
env:
HOF_TELEMETRY_DISABLED: "1"
jobs:
docs:
runs-on: ubuntu-latest
environment: hof docs
steps:
- name: cancel if not our repository
run: |-
gh run cancel ${{ github.run_id }}
gh run watch ${{ github.run_id }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
if: github.repository != hofstadter-io/hof
- run: |-
mkdir tmp
cd tmp
wget https://github.com/cue-lang/cue/releases/download/v0.8.2/cue_v0.8.2_linux_amd64.tar.gz -O cue.tar.gz
tar -xf cue.tar.gz
sudo mv cue /usr/local/bin/cue
cd ../
rm -rf tmp
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: 1.23.x
- name: Checkout code
uses: actions/checkout@v4
- name: Setup Vars
id: vars
run: |-
SHA=${GITHUB_SHA::8}
TAG=$(git tag --points-at HEAD)
echo "HOF_FMT_VERSION=${TAG}" >> $GITHUB_ENV
if [ -z $TAG ]; then
TAG=${SHA}
fi
echo "HOF_SHA=${SHA}" >> $GITHUB_ENV
echo "HOF_TAG=${TAG}" >> $GITHUB_ENV
- name: Fetch Go deps
run: go mod download
- name: Build hof
run: go install ./cmd/hof
- name: Setup
run: |-
hof fmt start [email protected]
cd docs
hof mod link
make tools
make deps
- name: Docs Env
run: |-
D="next"
[[ "$HOF_TAG" =~ ^docs-20[0-9]{6}.[0-9]+$ ]] && D="prod"
echo "DOCS_ENV=${D}" >> $GITHUB_ENV
- name: Build
run: |-
cd docs
make gen
make hugo.${DOCS_ENV}
- name: GCloud Auth
uses: google-github-actions/auth@v1
with:
credentials_json: ${{ secrets.HOF_GCLOUD_JSON }}
- name: GCloud Setup
uses: google-github-actions/setup-gcloud@v1
- name: Docker Auth
run: gcloud auth configure-docker
- name: Image
run: |-
export TAG=${HOF_TAG}
cd docs
make docker
make push
make deploy.${DOCS_ENV}.view
strategy: {}
services: {}