Skip to content

Commit 9cfa6b0

Browse files
committed
Mirror generate-groups.sh to satisfy make generate
1 parent c348b80 commit 9cfa6b0

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

vendor/k8s.io/code-generator/generate-groups.sh renamed to hack/generate-groups.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@
1414
# See the License for the specific language governing permissions and
1515
# limitations under the License.
1616

17+
# This is a snapshot of https://github.com/kubernetes/code-generator/blob/50b561225d70b3eb79a1faafd3dfe7b1a62cbe73/generate-groups.sh
18+
1719
set -o errexit
1820
set -o nounset
1921
set -o pipefail

hack/update-codegen.sh

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,14 @@ CODEGEN_PKG=${CODEGEN_PKG:-$(cd "${SCRIPT_ROOT}"; ls -d -1 ./vendor/k8s.io/code-
2525
# --output-base because this script should also be able to run inside the vendor dir of
2626
# k8s.io/kubernetes. The output-base is needed for the generators to output into the vendor dir
2727
# instead of the $GOPATH directly. For normal projects this can be dropped.
28+
29+
# go modules do not bring this file so we create a runtime symbolic link from our copy.
30+
cp "${SCRIPT_ROOT}"/hack/generate-groups.sh "${CODEGEN_PKG}"/generate-groups.sh
2831
"${CODEGEN_PKG}"/generate-groups.sh "deepcopy,client" \
2932
github.com/openshift/machine-api-operator/pkg/generated \
3033
github.com/openshift/machine-api-operator/pkg/apis \
3134
healthchecking:v1alpha1 \
3235
--output-base "$(dirname "${BASH_SOURCE[0]}")/../../../.." \
3336
--go-header-file "${SCRIPT_ROOT}"/hack/boilerplate.go.txt
37+
38+
rm -f "${CODEGEN_PKG}"/generate-groups.sh

0 commit comments

Comments
 (0)