Skip to content

Commit

Permalink
build: only update docs, schema, after a release
Browse files Browse the repository at this point in the history
closes #4402
  • Loading branch information
caarlos0 committed Nov 4, 2023
1 parent 8cd3104 commit 178ce2a
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 85 deletions.
28 changes: 0 additions & 28 deletions .github/workflows/generate-releases.yml

This file was deleted.

12 changes: 3 additions & 9 deletions .github/workflows/generate.yml
@@ -1,22 +1,15 @@
name: generate

on:
push:
branches:
- 'main'
paths:
- '.github/workflows/generate.yml'
- pkg/config/config.go
- CONTRIBUTING.md
- USERS.md
workflow_dispatch: {}

permissions:
contents: read

jobs:
docs:
permissions:
contents: write # for stefanzweifel/git-auto-commit-action to push code in repo
contents: write
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v3
Expand All @@ -27,6 +20,7 @@ jobs:
go-version: stable
cache: true
- uses: arduino/setup-task@e26d8975574116b0097a1161e0fe16ba75d84c1c # v1
- run: task docs:releases
- run: task docs:generate
- run: task schema:generate
- uses: stefanzweifel/git-auto-commit-action@8756aa072ef5b4a080af5dc8fef36c5d586e521d # v5
Expand Down
14 changes: 7 additions & 7 deletions .github/workflows/release.yml
Expand Up @@ -3,9 +3,9 @@ name: release
on:
push:
branches:
- 'main'
- "main"
tags:
- 'v*'
- "v*"

permissions:
contents: write
Expand All @@ -15,18 +15,18 @@ permissions:
jobs:
trigger-generate:
runs-on: ubuntu-latest
needs: [ goreleaser ]
needs: [goreleaser]
steps:
- uses: benc-uk/workflow-dispatch@v121
if: startsWith(github.ref, 'refs/tags/v')
with:
repo: goreleaser/goreleaser
ref: main
token: ${{ secrets.GH_PAT }}
workflow: generate-releases.yml
workflow: generate.yml
notify-goreleaser-cross:
runs-on: ubuntu-latest
needs: [ trigger-generate ]
needs: [trigger-generate]
steps:
- name: get version
if: startsWith(github.ref, 'refs/tags/v')
Expand All @@ -43,11 +43,11 @@ jobs:
runs-on: ubuntu-latest
env:
DOCKER_CLI_EXPERIMENTAL: "enabled"
needs: [ goreleaser ]
needs: [goreleaser]
if: github.ref == 'refs/heads/main'
strategy:
matrix:
format: [ deb, rpm, apk ]
format: [deb, rpm, apk]
steps:
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v3
with:
Expand Down
23 changes: 2 additions & 21 deletions www/docs/static/schema-pro.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

22 changes: 2 additions & 20 deletions www/docs/static/schema.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 178ce2a

Please sign in to comment.