diff --git a/pseudo/update-fork-references.sh b/pseudo/update-fork-references.sh deleted file mode 100755 index cbae2b475..000000000 --- a/pseudo/update-fork-references.sh +++ /dev/null @@ -1,85 +0,0 @@ -#!/bin/bash - -set -e -set -o xtrace - -# replace the module name with the new module name -function replaceModuleName { - find . -name *.go | xargs sed -i -e "s!sigs.k8s.io/kustomize/pseudo/k8s/$1!k8s.io/$1!g" - find . -name *.proto | xargs sed -i -e "s!sigs.k8s.io/kustomize/pseudo/k8s/$1!k8s.io/$1!g" - find . -name *.md | xargs sed -i -e "s!sigs.k8s.io/kustomize/pseudo/k8s/$1!k8s.io/$1!g" -} - -# update the go.mod file, dropping the old module -function updateGoModFile { - go mod edit -droprequire=k8s.io/$1 || echo "" - rm go.sum || echo "" -} - -# test the module -function testGoMod { - go test ./... - gofmt -s -w . - go mod tidy -} - -# update all go.mod files -function updateAllGoModFiles { - (cd api; updateGoModFile $1 ) - (cd kustomize; updateGoModFile $1 ) - (cd hack/crawl; updateGoModFile $1 ) - (cd pluginator; updateGoModFile $1 ) - - for goMod in $(find ./plugin/builtin -name 'go.mod'); do - dir=$(dirname "${goMod}") - (cd $dir; updateGoModFile $1 ) - done - - for goMod in $(find ./plugin/someteam.example.com/v1 -name 'go.mod'); do - dir=$(dirname "${goMod}") - (cd $dir; updateGoModFile $1 ) - done -} - -# test all go modules -function testAllModules { - (cd api; testGoMod) - (cd kustomize; testGoMod) - (cd hack/crawl; testGoMod) - (cd pluginator; testGoMod ) - - for goMod in $(find ./plugin/builtin -name 'go.mod'); do - dir=$(dirname "${goMod}") - (cd $dir; testGoMod ) - done - -# Uncomment this when tests are added for this module -# for goMod in $(find ./plugin/someteam.example.com/v1 -name 'go.mod'); do -# dir=$(dirname "${goMod}") -# (cd $dir; testGoMod ) -# done -} - -# verify the package dependencies -for item in $(find . -name go.mod | sed s/go.mod//g) -do - cd $item - go fmt ./... - cd - -done - - -# update the names of the modules -for item in api apimachinery client-go -do - replaceModuleName $item -done - -# update the go.mod files -for item in api apimachinery client-go -do - updateAllGoModFiles $item -done - -# test all of the modules still work -testAllModules diff --git a/releasing/README.md b/releasing/README.md index 7f01ee919..366f31ade 100644 --- a/releasing/README.md +++ b/releasing/README.md @@ -20,7 +20,6 @@ for an explanation of the `foo/v2.3.0` tags applied below. [`sigs.k8s.io/kustomize/kustomize`]: #sigsk8siokustomizekustomize [`sigs.k8s.io/kustomize/api`]: #sigsk8siokustomizeapi [`sigs.k8s.io/kustomize/pluginator`]: #sigsk8siokustomizepluginator -[`sigs.k8s.io/kustomize/pseudo/k8s`]: #sigsk8siokustomizepseudok8s [kustomize/v3.2.1]: /../../releases/tag/kustomize%2Fv3.2.1 [pluginator/v1.0.0]: /../../releases/tag/pluginator%2Fv1.0.0 @@ -29,7 +28,6 @@ for an explanation of the `foo/v2.3.0` tags applied below. | kustomize executable | [`sigs.k8s.io/kustomize/kustomize`] | _kustomize/v3.2.2_ | _release-kustomize-v3.2.2_ | | kustomize Go API | [`sigs.k8s.io/kustomize/api`] | _api/v0.1.0_ | _release-api-v0.1_ | | pluginator executable | [`sigs.k8s.io/kustomize/pluginator`] | _pluginator/v1.0.0_ | _release-pluginator-v1.0_ | -| pseudo k8s API | [`sigs.k8s.io/kustomize/pseudo/k8s`] | _pseudo/k8s/v0.1.0_ | _release-pseudok8s-v0.1.0_ | ### sigs.k8s.io/kustomize/kustomize @@ -112,36 +110,6 @@ infrequently). Executables appear on the [release page]. The tag appears in the URL, e.g. [pluginator/v1.0.0]. -### sigs.k8s.io/kustomize/pseudo/k8s - - -This is a clone of a combination of kubernetes repositories. -See the [README](../pseudo/README.md). - -#### Packages - -The packages in this module are used by kubernetes -clients like the kustomize API. - -Go consumers of this API will have a `go.mod` file -requiring this module at a particular tag, e.g. - -``` -require sigs.k8s.io/pseudo/k8s v0.1.0 -``` - -#### Release artifacts - -This is a Go library-only release, so the only -artifact per se is the repo tag, in the form `pseudo/k8s/v0.1.0`, -that API clients can `require` from their `go.mod` file. - -Release notes should appear on the [release page]. - -There's a toy executable called `pseudok8s`, which, if -run, prints a message, but is of -no practical use to an API client. - ## Release procedure > TODO: script what follows, so someone can enter @@ -173,7 +141,6 @@ git rebase upstream/master module=pluginator # The pluginator executable module=kustomize # The kustomize executable module=api # The API -module=pseudo/k8s # The clone of the k8s API ``` ### review tags to help determine new tag diff --git a/releasing/cloudbuild.sh b/releasing/cloudbuild.sh index c9be0cabd..1fc28aa49 100755 --- a/releasing/cloudbuild.sh +++ b/releasing/cloudbuild.sh @@ -42,10 +42,6 @@ setSemVer cd $module -# Remove slash from module name -# (pseudo/k8s becomes pseudok8s) -module=$(echo $module | sed 's|/||') - configFile=$(mktemp) cat <$configFile project_name: $module diff --git a/releasing/cloudbuild_pseudok8s.yaml b/releasing/cloudbuild_pseudok8s.yaml deleted file mode 100644 index 15906b997..000000000 --- a/releasing/cloudbuild_pseudok8s.yaml +++ /dev/null @@ -1,11 +0,0 @@ -steps: -- name: "gcr.io/cloud-builders/git" - args: [fetch, --tags, --depth=100] -- name: "goreleaser/goreleaser:v0.120.3" - entrypoint: /bin/sh - args: ["releasing/cloudbuild.sh", "pseudo/k8s"] - secretEnv: ['GITHUB_TOKEN'] -secrets: -- kmsKeyName: projects/kustomize-199618/locations/global/keyRings/github-tokens/cryptoKeys/gh-release-token - secretEnv: - GITHUB_TOKEN: CiQAyrREbPgXJOeT7M3t+WlxkhXwlMPudixBeiyWTjmLOMLqdK4SUQA0W+xUmDJKAhyfHCcwqSEzUn9OwKC7XAYcmwe0CCKTCbPbDgmioDK24q3LVapndXNvnnHvCjhOJNEr1o+P1DCF+LlzYV2YL8lP09rrKrslPg== diff --git a/releasing/localbuild.sh b/releasing/localbuild.sh index 986b8c731..5f2b5b3b7 100755 --- a/releasing/localbuild.sh +++ b/releasing/localbuild.sh @@ -9,7 +9,6 @@ # module=kustomize # module=pluginator # pick one # module=api -# module=pseudo/k8s # # ./releasing/localbuild.sh $module # @@ -39,7 +38,6 @@ set -e module=$1 -cbname=$module case "$module" in api) ;; @@ -47,9 +45,6 @@ case "$module" in ;; pluginator) ;; - pseudo/k8s) - cbname=pseudok8s - ;; *) echo "Don't recognize module=$module" exit 1 @@ -57,7 +52,7 @@ case "$module" in esac config=$(mktemp) -cp releasing/cloudbuild_${cbname}.yaml $config +cp releasing/cloudbuild_${module}.yaml $config # Delete the cloud-builders/git step, which isn't needed # for a local run.