minikube/.github/workflows/docs.yml

50 lines
1.6 KiB
YAML
Raw Normal View History

2021-06-16 17:06:28 +00:00
name: "generate-docs"
on:
workflow_dispatch:
2021-06-17 19:08:50 +00:00
push:
2021-06-17 20:51:37 +00:00
branches:
2021-06-17 19:08:50 +00:00
- master
2021-06-23 16:38:59 +00:00
env:
GOPROXY: https://proxy.golang.org
2022-06-13 09:02:11 +00:00
GO_VERSION: '1.18.3'
permissions:
contents: read
2021-06-16 17:06:28 +00:00
jobs:
generate-docs:
2022-06-09 17:11:22 +00:00
if: github.repository == 'kubernetes/minikube'
2021-09-28 03:01:27 +00:00
runs-on: ubuntu-20.04
2021-06-16 17:06:28 +00:00
steps:
2022-03-25 22:21:45 +00:00
- uses: actions/checkout@629c2de402a417ea7690ca6ce3f33229e27606a5
- uses: actions/setup-go@84cbf8094393cdc5fe1fe1671ff2647332956b1a
2021-06-17 19:19:32 +00:00
with:
2021-06-23 16:38:59 +00:00
go-version: ${{env.GO_VERSION}}
- name: Generate Docs
id: gendocs
2021-06-16 17:06:28 +00:00
run: |
2021-06-29 20:34:04 +00:00
make generate-docs
c=$(git status --porcelain)
c="${c//$'\n'/'%0A'}"
c="${c//$'\r'/'%0D'}"
echo "::set-output name=changes::$c"
2021-06-29 20:34:04 +00:00
- name: Create PR
2021-06-30 00:42:30 +00:00
if: ${{ steps.gendocs.outputs.changes != '' }}
uses: peter-evans/create-pull-request@923ad837f191474af6b1721408744feb989a4c27
2021-06-29 20:34:04 +00:00
with:
token: ${{ secrets.MINIKUBE_BOT_PAT }}
commit-message: Update auto-generated docs and translations
committer: minikube-bot <minikube-bot@google.com>
author: minikube-bot <minikube-bot@google.com>
branch: gendocs
2021-06-29 20:52:45 +00:00
push-to-fork: minikube-bot/minikube
2021-06-29 20:41:23 +00:00
base: master
2021-06-29 20:34:04 +00:00
delete-branch: true
title: 'Update auto-generated docs and translations'
2021-07-01 19:41:09 +00:00
body: |
2021-07-01 19:55:01 +00:00
Committing changes resulting from `make generate-docs`.
This PR is auto-generated by the [gendocs](https://github.com/kubernetes/minikube/blob/master/.github/workflows/docs.yml) CI workflow.
2021-07-01 19:41:09 +00:00
```
${{ steps.gendocs.outputs.changes }}
```