mirror of
https://github.com/strukturag/nextcloud-spreed-signaling
synced 2026-03-14 14:35:44 +01:00
CI: Update paths for checking generated files.
This commit is contained in:
parent
d97080c118
commit
a3afe9429d
1 changed files with 16 additions and 13 deletions
29
.github/workflows/generated.yml
vendored
29
.github/workflows/generated.yml
vendored
|
|
@ -5,20 +5,24 @@ on:
|
|||
branches: [ master ]
|
||||
paths:
|
||||
- '.github/workflows/generated.yml'
|
||||
- 'api*.go'
|
||||
- '*_easyjson.go'
|
||||
- '*.pb.go'
|
||||
- '*.proto'
|
||||
- '**/api*.go'
|
||||
- '**/*_easyjson.go'
|
||||
- '**/*.pb.go'
|
||||
- '**/*.proto'
|
||||
- 'go.*'
|
||||
- 'api/signaling.go'
|
||||
- 'talk/ocs.go'
|
||||
pull_request:
|
||||
branches: [ master ]
|
||||
paths:
|
||||
- '.github/workflows/generated.yml'
|
||||
- 'api*.go'
|
||||
- '*_easyjson.go'
|
||||
- '*.pb.go'
|
||||
- '*.proto'
|
||||
- '**/api*.go'
|
||||
- '**/*_easyjson.go'
|
||||
- '**/*.pb.go'
|
||||
- '**/*.proto'
|
||||
- 'go.*'
|
||||
- 'api/signaling.go'
|
||||
- 'talk/ocs.go'
|
||||
|
||||
env:
|
||||
CODE_GENERATOR_NAME: struktur AG service user
|
||||
|
|
@ -78,16 +82,15 @@ jobs:
|
|||
if [ "$CHECKOUT_SHA" != "${{github.event.pull_request.head.sha}}" ]; then
|
||||
echo "More changes since this commit ${{github.event.pull_request.head.sha}}, skipping"
|
||||
else
|
||||
git add *_easyjson.go *.pb.go
|
||||
git add --all
|
||||
CHANGES=$(git status --porcelain)
|
||||
if [ -z "$CHANGES" ]; then
|
||||
echo "No files have changed, no need to commit / push."
|
||||
else
|
||||
go mod tidy
|
||||
git add go.*
|
||||
git config user.name "$CODE_GENERATOR_NAME"
|
||||
git config user.email "$CODE_GENERATOR_EMAIL"
|
||||
git commit --author="$(git log -n 1 --pretty=format:%an) <$(git log -n 1 --pretty=format:%ae)>" -m "Update generated files from ${{github.event.pull_request.head.sha}}"
|
||||
git commit --all --author="$(git log -n 1 --pretty=format:%an) <$(git log -n 1 --pretty=format:%ae)>" -m "Update generated files from ${{github.event.pull_request.head.sha}}"
|
||||
git push
|
||||
fi
|
||||
fi
|
||||
|
|
@ -113,5 +116,5 @@ jobs:
|
|||
|
||||
- name: Check generated files
|
||||
run: |
|
||||
git add *.go
|
||||
git diff --cached --exit-code *.go
|
||||
git add --all
|
||||
git diff --cached --exit-code
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue