Skip to content

Commit 769632a

Browse files
authored
chore: simplify go generate in examples (#3033)
1 parent f24ae88 commit 769632a

File tree

3 files changed

+2
-7
lines changed

3 files changed

+2
-7
lines changed

‎.github/workflows/check-generate‎

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,8 @@
11
#!/bin/bash
22
set -exuo pipefail
33
export GO111MODULE=on
4-
echo Generating in root
4+
echo Generating code
55
go generate ./...
6-
echo Swithcing to _examples and generating again
7-
cd _examples && go generate ./...
86
if [[ $(git --no-pager diff) ]] ; then
97
echo "you need to run "go generate ./..." and commit the changes"
108
git --no-pager diff

‎generate_examples.sh‎

Lines changed: 0 additions & 3 deletions
This file was deleted.

‎main.go‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
package main
22

3-
//go:generate sh generate_examples.sh
3+
//go:generate sh -c "cd _examples && go generate ./..."
44

55
import (
66
"bytes"

0 commit comments

Comments
 (0)