]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/go: remove temporary rf cleanup script
authorIan Alexander <jitsu@google.com>
Wed, 8 Oct 2025 23:22:59 +0000 (19:22 -0400)
committerIan Alexander <jitsu@google.com>
Sun, 26 Oct 2025 21:09:48 +0000 (14:09 -0700)
This commit is part of the overall effort to eliminate global
modloader state.

Change-Id: I9d2deebafbbb374de2a1f9bae99e9caf417313a0
Reviewed-on: https://go-review.googlesource.com/c/go/+/709991
Reviewed-by: Michael Matloob <matloob@golang.org>
Reviewed-by: Michael Matloob <matloob@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>

src/cmd/go/internal/rf-cleanup.zsh [deleted file]

diff --git a/src/cmd/go/internal/rf-cleanup.zsh b/src/cmd/go/internal/rf-cleanup.zsh
deleted file mode 100755 (executable)
index c805db5..0000000
+++ /dev/null
@@ -1,43 +0,0 @@
-#!/usr/bin/env zsh
-
-set -eu -o pipefail
-
-# This is a large series of sed commands to cleanup after successful use of the
-# `rf inject` command.  This script will be used to refactor the codebase to
-# eliminate global state within the module loader.  Once that effort is
-# complete, this script will be removed.
-
-find . -name '*.go' -exec \
-  sed -i '
-    #
-    # CompileAction does not use loaderstate.
-    #
-    s/CompileAction(loaderstate[^ ]* \*modload.State, /CompileAction(/g
-    s/CompileAction(modload.LoaderState[^,]*, /CompileAction(/g
-    s/CompileAction(loaderstate[^,]*, /CompileAction(/g
-    #
-    # cgoAction does not use loaderstate.
-    #
-    s/cgoAction(loaderstate \*modload\.State, /cgoAction(/g
-    s/cgoAction(loaderstate, /cgoAction(/g
-    s/cgoAction(loaderstate_, /cgoAction(/g
-    #
-    # Remove redundant mentions of LoaderState from function call sites.
-    #
-    s/(modload\.LoaderState_*, loaderstate,/(loaderstate,/g
-    s/(modload\.LoaderState_*, moduleLoaderState,/(moduleLoaderState,/g
-    s/(modload\.LoaderState_*, modload\.LoaderState/(modload.LoaderState/g
-    s/(modload\.LoaderState_*, loaderstate,/(loaderstate,/g
-    s/(modload\.LoaderState_*, moduleLoaderState,/(moduleLoaderState,/g
-    s/(modload\.LoaderState_*, modload\.LoaderState,/(modload.LoaderState,/g
-    s/(loaderstate_* \*modload.State, loaderstate \*modload.State/(loaderstate *modload.State/g
-    s/(loaderstate_* \*State, loaderstate \*State/(loaderstate *State/g
-    s/(loaderstate_*, loaderstate,/(loaderstate,/g
-    s/(LoaderState_*, loaderstate,/(loaderstate,/g
-    s/(LoaderState_*, loaderState,/(loaderState,/g
-    s/(LoaderState_*, LoaderState,/(LoaderState,/g
-    s/(LoaderState_*, LoaderState,/(LoaderState,/g
-    s/(moduleLoaderState_*, loaderstate,/(loaderstate,/g
-    s/(moduleLoaderState_*, moduleLoaderState,/(moduleLoaderState,/g
-  ' {} \;
-