Repository: GoogleContainerTools/skaffold
Pull request #7961 (2022-10-20 01:13:03)

chore: add generic `util.Ptr` function
Replace `util.StringPtr`, `util.IntPtr` and `util.BoolPtr` with a generic `util.Ptr` 🥹
```
func Ptr[T any](t T) *T {
	o := t
	return &o
}
```

codecov[bot]: # [Codecov](https://codecov.io/gh/GoogleContainerTools/skaffold/pull/7961?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=GoogleContainerTools) Report
> Merging [#7961](https://codecov.io/gh/GoogleContainerTools/skaffold/pull/7961?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=GoogleContainerTools) (9323b81) into [main](https://codecov.io/gh/GoogleContainerTools/skaffold/commit/290280e8c6c19231e9ed5b5c027f2c01d22f75be?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=GoogleContainerTools) (290280e) will **decrease** coverage by `3.74%`.
> The diff coverage is `54.09%`.

```diff
@@            Coverage Diff             @@
##             main    #7961      +/-   ##
==========================================
- Coverage   70.48%   66.73%   -3.75%     
==========================================
  Files         515      594      +79     
  Lines       23150    28794    +5644     
==========================================
+ Hits        16317    19216    +2899     
- Misses       5776     8153    +2377     
- Partials     1057     1425     +368     
```


| [Impacted Files](https://codecov.io/gh/GoogleContainerTools/skaffold/pull/7961?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=GoogleContainerTools) | Coverage Δ | |
|---|---|---|
| [cmd/skaffold/app/cmd/credits/export.go](https://codecov.io/gh/GoogleContainerTools/skaffold/pull/7961/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=GoogleContainerTools#diff-Y21kL3NrYWZmb2xkL2FwcC9jbWQvY3JlZGl0cy9leHBvcnQuZ28=) | `0.00% <0.00%> (ø)` | |
| [cmd/skaffold/app/cmd/deploy.go](https://codecov.io/gh/GoogleContainerTools/skaffold/pull/7961/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=GoogleContainerTools#diff-Y21kL3NrYWZmb2xkL2FwcC9jbWQvZGVwbG95Lmdv) | `40.90% <0.00%> (-12.94%)` | :arrow_down: |
| [cmd/skaffold/app/cmd/test.go](https://codecov.io/gh/GoogleContainerTools/skaffold/pull/7961/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=GoogleContainerTools#diff-Y21kL3NrYWZmb2xkL2FwcC9jbWQvdGVzdC5nbw==) | `44.44% <0.00%> (ø)` | |
| [cmd/skaffold/app/exitcode.go](https://codecov.io/gh/GoogleContainerTools/skaffold/pull/7961/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=GoogleContainerTools#diff-Y21kL3NrYWZmb2xkL2FwcC9leGl0Y29kZS5nbw==) | `100.00% <ø> (+6.66%)` | :arrow_up: |
| [cmd/skaffold/skaffold.go](https://codecov.io/gh/GoogleContainerTools/skaffold/pull/7961/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=GoogleContainerTools#diff-Y21kL3NrYWZmb2xkL3NrYWZmb2xkLmdv) | `0.00% <0.00%> (ø)` | |
| [cmd/skaffold/app/cmd/inspect\_tests.go](https://codecov.io/gh/GoogleContainerTools/skaffold/pull/7961/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=GoogleContainerTools#diff-Y21kL3NrYWZmb2xkL2FwcC9jbWQvaW5zcGVjdF90ZXN0cy5nbw==) | `62.50% <14.28%> (-1.14%)` | :arrow_down: |
| [cmd/skaffold/app/cmd/render.go](https://codecov.io/gh/GoogleContainerTools/skaffold/pull/7961/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=GoogleContainerTools#diff-Y21kL3NrYWZmb2xkL2FwcC9jbWQvcmVuZGVyLmdv) | `35.48% <18.18%> (-5.90%)` | :arrow_down: |
| [cmd/skaffold/app/cmd/lsp.go](https://codecov.io/gh/GoogleContainerTools/skaffold/pull/7961/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=GoogleContainerTools#diff-Y21kL3NrYWZmb2xkL2FwcC9jbWQvbHNwLmdv) | `28.12% <28.12%> (ø)` | |
| [cmd/skaffold/app/cmd/run.go](https://codecov.io/gh/GoogleContainerTools/skaffold/pull/7961/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=GoogleContainerTools#diff-Y21kL3NrYWZmb2xkL2FwcC9jbWQvcnVuLmdv) | `64.28% <33.33%> (-9.63%)` | :arrow_down: |
| [cmd/skaffold/app/cmd/fix.go](https://codecov.io/gh/GoogleContainerTools/skaffold/pull/7961/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=GoogleContainerTools#diff-Y21kL3NrYWZmb2xkL2FwcC9jbWQvZml4Lmdv) | `56.41% <37.50%> (-20.07%)` | :arrow_down: |
| ... and [389 more](https://codecov.io/gh/GoogleContainerTools/skaffold/pull/7961/diff?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=GoogleContainerTools) | |

:mega: We’re building smart automated test selection to slash your CI/CD build times. [Learn more](https://about.codecov.io/iterative-testing/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=GoogleContainerTools)


Patch:
diff --git a/cmd/skaffold/app/cmd/diagnose.go b/cmd/skaffold/app/cmd/diagnose.go
index aa846ab42..131889c60 100644
--- a/cmd/skaffold/app/cmd/diagnose.go
+++ b/cmd/skaffold/app/cmd/diagnose.go
@@ -55,7 +55,7 @@ func NewCmdDiagnose() *cobra.Command {
 
 func doDiagnose(ctx context.Context, out io.Writer) error {
 	// force absolute path resolution during diagnose
-	opts.MakePathsAbsolute = util.BoolPtr(true)
+	opts.MakePathsAbsolute = util.Ptr(true)
 	configs, err := getCfgs(ctx, opts)
 	if err != nil {
 		return err
diff --git a/pkg/skaffold/build/cluster/cluster.go b/pkg/skaffold/build/cluster/cluster.go
index 3b7a38d59..5d12cd3d1 100644
--- a/pkg/skaffold/build/cluster/cluster.go
+++ b/pkg/skaffold/build/cluster/cluster.go
@@ -77,7 +77,7 @@ func (b *Builder) buildArtifact(ctx context.Context, out io.Writer, artifact *la
 }
 
 func (b *Builder) Concurrency() *int {
-	return util.IntPtr(b.ClusterDetails.Concurrency)
+	return util.Ptr(b.ClusterDetails.Concurrency)
 }
 
 func (b *Builder) runBuildForArtifact(ctx context.Context, out io.Writer, a *latest.Artifact, tag string, platforms platform.Matcher) (string, error) {
diff --git a/pkg/skaffold/build/gcb/cloud_build.go b/pkg/skaffold/build/gcb/cloud_build.go
index 0ecf00dbf..c59c039c4 100644
--- a/pkg/skaffold/build/gcb/cloud_build.go
+++ b/pkg/skaffold/build/gcb/cloud_build.go
@@ -67,7 +67,7 @@ func (b *Builder) PostBuild(_ context.Context, _ io.Writer) error {
 }
 
 func (b *Builder) Concurrency() *int {
-	return util.IntPtr(b.GoogleCloudBuild.Concurrency)
+	return util.Ptr(b.GoogleCloudBuild.Concurrency)
 }
 
 func (b *Builder) buildArtifactWithCloudBuild(ctx context.Context, out io.Writer, artifact *latest.Artifact, tag string, platform platform.Matcher) (string, error) {
diff --git a/pkg/skaffold/build/ko/builder.go b/pkg/skaffold/build/ko/builder.go
index 1bd03f8e7..61237a9ee 100644
--- a/pkg/skaffold/build/ko/builder.go
+++ b/pkg/skaffold/build/ko/builder.go
@@ -123,7 +123,7 @@ func koArtifactSpecifiesBuildConfig(k latest.KoArtifact) bool {
 func labels(a *latest.Artifact) ([]string, error) {
 	rawLabels := map[string]*string{}
 	for k, v := range a.KoArtifact.Labels {
-		rawLabels[k] = util.StringPtr(v)
+		rawLabels[k] = util.Ptr(v)
 	}
 	expandedLabels, err := util.EvaluateEnvTemplateMapWithEnv(rawLabels, nil)
 	if err != nil {
diff --git a/pkg/skaffold/config/types.go b/pkg/skaffold/config/types.go
index 7a30d3983..33b245676 100644
--- a/pkg/skaffold/config/types.go
+++ b/pkg/skaffold/config/types.go
@@ -87,9 +87,9 @@ func (s *BoolOrUndefined) Value() *bool {
 func (s *BoolOrUndefined) Set(v string) error {
 	switch v {
 	case "true":
-		s.value = util.BoolPtr(true)
+		s.value = util.Ptr(true)
 	case "false":
-		s.value = util.BoolPtr(false)
+		s.value = util.Ptr(false)
 	default:
 		s.value = nil
 	}
diff --git a/pkg/skaffold/config/util.go b/pkg/skaffold/config/util.go
index 71d2bbda2..adfe679c7 100644
--- a/pkg/skaffold/config/util.go
+++ b/pkg/skaffold/config/util.go
@@ -566,9 +566,9 @@ func UpdateUserSurveyTaken(configFile string, id string) error {
 func updatedUserSurveys(us []*UserSurvey, id string) []*UserSurvey {
 	for _, s := range us {
 		if s.ID == id {
-			s.Taken = util.BoolPtr(true)
+			s.Taken = util.Ptr(true)
 			return us
 		}
 	}
-	return append(us, &UserSurvey{ID: id, Taken: util.BoolPtr(true)})
+	return append(us, &UserSurvey{ID: id, Taken: util.Ptr(true)})
 }
diff --git a/pkg/skaffold/docker/build_args.go b/pkg/skaffold/docker/build_args.go
index 4d3c9dfaf..17a2e88ed 100644
--- a/pkg/skaffold/docker/build_args.go
+++ b/pkg/skaffold/docker/build_args.go
@@ -56,7 +56,7 @@ func evalBuildArgs(mode config.RunMode, workspace string, dockerfilePath string,
 		defaults = nonDebugModeArgs
 	}
 	result := map[string]*string{
-		"SKAFFOLD_RUN_MODE": util.StringPtr(string(mode)),
+		"SKAFFOLD_RUN_MODE": util.Ptr(string(mode)),
 	}
 	for k, v := range defaults {
 		result[k] = &v
diff --git a/pkg/skaffold/hooks/sync.go b/pkg/skaffold/hooks/sync.go
index 25f800bb6..e4fbdc4e8 100644
--- a/pkg/skaffold/hooks/sync.go
+++ b/pkg/skaffold/hooks/sync.go
@@ -42,8 +42,8 @@ func NewSyncEnvOpts(a *latest.Artifact, image string, addOrModifyFiles []string,
 	return SyncEnvOpts{
 		Image:                image,
 		BuildContext:         workDir,
-		FilesAddedOrModified: util.StringPtr(strings.Join(addOrModifyFiles, ";")),
-		FilesDeleted:         util.StringPtr(strings.Join(deleteFiles, ";")),
+		FilesAddedOrModified: util.Ptr(strings.Join(addOrModifyFiles, ";")),
+		FilesDeleted:         util.Ptr(strings.Join(deleteFiles, ";")),
 		KubeContext:          kubeContext,
 		Namespaces:           strings.Join(namespaces, ","),
 	}, nil
diff --git a/pkg/skaffold/inspect/buildEnv/add_cluster.go b/pkg/skaffold/inspect/buildEnv/add_cluster.go
index 13b1ec4b2..fcf9eac8f 100644
--- a/pkg/skaffold/inspect/buildEnv/add_cluster.go
+++ b/pkg/skaffold/inspect/buildEnv/add_cluster.go
@@ -34,7 +34,7 @@ func AddClusterBuildEnv(ctx context.Context, out io.Writer, opts inspect.Options
 		RepoCacheDir:        opts.RepoCacheDir,
 		ConfigurationFilter: opts.Modules,
 		SkipConfigDefaults:  true,
-		MakePathsAbsolute:   util.BoolPtr(false),
+		MakePathsAbsolute:   util.Ptr(false),
 	})
 	if err != nil {
 		formatter.WriteErr(err)
diff --git a/pkg/skaffold/inspect/buildEnv/add_gcb.go b/pkg/skaffold/inspect/buildEnv/add_gcb.go
index f3d77a248..dacedfb92 100644
--- a/pkg/skaffold/inspect/buildEnv/add_gcb.go
+++ b/pkg/skaffold/inspect/buildEnv/add_gcb.go
@@ -35,7 +35,7 @@ func AddGcbBuildEnv(ctx context.Context, out io.Writer, opts inspect.Options) er
 		RepoCacheDir:        opts.RepoCacheDir,
 		ConfigurationFilter: opts.Modules,
 		SkipConfigDefaults:  true,
-		MakePathsAbsolute:   util.BoolPtr(false)})
+		MakePathsAbsolute:   util.Ptr(false)})
 	if err != nil {
 		formatter.WriteErr(err)
 		return err
diff --git a/pkg/skaffold/inspect/buildEnv/add_local.go b/pkg/skaffold/inspect/buildEnv/add_local.go
index 3442d1358..28d51fad0 100644
--- a/pkg/skaffold/inspect/buildEnv/add_local.go
+++ b/pkg/skaffold/inspect/buildEnv/add_local.go
@@ -28,7 +28,7 @@ import (
 
 func AddLocalBuildEnv(ctx context.Context, out io.Writer, opts inspect.Options) error {
 	formatter := inspect.OutputFormatter(out, opts.OutFormat)
-	cfgs, err := inspect.GetConfigSet(ctx, config.SkaffoldOptions{ConfigurationFile: opts.Filename, ConfigurationFilter: opts.Modules, SkipConfigDefaults: true, MakePathsAbsolute: util.BoolPtr(false)})
+	cfgs, err := inspect.GetConfigSet(ctx, config.SkaffoldOptions{ConfigurationFile: opts.Filename, ConfigurationFilter: opts.Modules, SkipConfigDefaults: true, MakePathsAbsolute: util.Ptr(false)})
 	if err != nil {
 		formatter.WriteErr(err)
 		return err
@@ -77,7 +77,7 @@ func constructLocalDefinition(existing *latest.LocalBuild, opts inspect.BuildEnv
 		b = *existing
 	}
 	if opts.Concurrency >= 0 {
-		b.Concurrency = util.IntPtr(opts.Concurrency)
+		b.Concurrency = util.Ptr(opts.Concurrency)
 	}
 	if opts.Push != nil {
 		b.Push = opts.Push
diff --git a/pkg/skaffold/inspect/buildEnv/modify_gcb.go b/pkg/skaffold/inspect/buildEnv/modify_gcb.go
index 56be7ea83..558c140b0 100644
--- a/pkg/skaffold/inspect/buildEnv/modify_gcb.go
+++ b/pkg/skaffold/inspect/buildEnv/modify_gcb.go
@@ -27,7 +27,7 @@ import (
 
 func ModifyGcbBuildEnv(ctx context.Context, out io.Writer, opts inspect.Options) error {
 	formatter := inspect.OutputFormatter(out, opts.OutFormat)
-	cfgs, err := inspect.GetConfigSet(ctx, config.SkaffoldOptions{ConfigurationFile: opts.Filename, ConfigurationFilter: opts.Modules, SkipConfigDefaults: true, MakePathsAbsolute: util.BoolPtr(false)})
+	cfgs, err := inspect.GetConfigSet(ctx, config.SkaffoldOptions{ConfigurationFile: opts.Filename, ConfigurationFilter: opts.Modules, SkipConfigDefaults: true, MakePathsAbsolute: util.Ptr(false)})
 	if err != nil {
 		formatter.WriteErr(err)
 		return err
diff --git a/pkg/skaffold/runner/deployer.go b/pkg/skaffold/runner/deployer.go
index 9994140d3..fe600eef3 100644
--- a/pkg/skaffold/runner/deployer.go
+++ b/pkg/skaffold/runner/deployer.go
@@ -227,7 +227,7 @@ func getDefaultDeployer(runCtx *runcontext.RunContext, labeller *label.DefaultLa
 				statusCheck = d.StatusCheck
 			} else if statusCheck != d.StatusCheck {
 				// if we get conflicting values for status check from different skaffold configs, we turn status check off
-				statusCheck = util.BoolPtr(false)
+				statusCheck = util.Ptr(false)
 			}
 		}
 		if d.StatusCheckDeadlineSeconds != 0 && d.StatusCheckDeadlineSeconds != int(status.DefaultStatusCheckDeadline.Seconds()) {
diff --git a/pkg/skaffold/schema/defaults/defaults.go b/pkg/skaffold/schema/defaults/defaults.go
index f2ef015b8..7dc3e1a30 100644
--- a/pkg/skaffold/schema/defaults/defaults.go
+++ b/pkg/skaffold/schema/defaults/defaults.go
@@ -267,13 +267,13 @@ func setDefaultSync(a *latest.Artifact) {
 		if len(a.Sync.Manual) == 0 && len(a.Sync.Infer) == 0 && a.Sync.Auto == nil {
 			switch {
 			case a.JibArtifact != nil || a.BuildpackArtifact != nil:
-				a.Sync.Auto = util.BoolPtr(true)
+				a.Sync.Auto = util.Ptr(true)
 			default:
 				a.Sync.Infer = []string{"**/*"}
 			}
 		}
 	} else if a.BuildpackArtifact != nil {
-		a.Sync = &latest.Sync{Auto: util.BoolPtr(true)}
+		a.Sync = &latest.Sync{Auto: util.Ptr(true)}
 	}
 }
 
diff --git a/pkg/skaffold/util/util.go b/pkg/skaffold/util/util.go
index 98dd26799..9af0ca0f2 100644
--- a/pkg/skaffold/util/util.go
+++ b/pkg/skaffold/util/util.go
@@ -109,21 +109,8 @@ func ExpandPathsGlob(workingDir string, paths []string) ([]string, error) {
 	return set.Files(), nil
 }
 
-// BoolPtr returns a pointer to a bool
-func BoolPtr(b bool) *bool {
-	o := b
-	return &o
-}
-
-// StringPtr returns a pointer to a string
-func StringPtr(s string) *string {
-	o := s
-	return &o
-}
-
-// IntPtr returns a pointer to an int
-func IntPtr(i int) *int {
-	o := i
+func Ptr[T any](t T) *T {
+	o := t
 	return &o
 }
 


Test patch:
diff --git a/cmd/skaffold/app/cmd/config/list_test.go b/cmd/skaffold/app/cmd/config/list_test.go
index 024afb9e3..b5c50ace4 100644
--- a/cmd/skaffold/app/cmd/config/list_test.go
+++ b/cmd/skaffold/app/cmd/config/list_test.go
@@ -47,15 +47,15 @@ func TestList(t *testing.T) {
 					{
 						Kubecontext:        "another_context",
 						DefaultRepo:        "other-value",
-						MultiLevelRepo:     util.BoolPtr(false),
-						LocalCluster:       util.BoolPtr(false),
+						MultiLevelRepo:     util.Ptr(false),
+						LocalCluster:       util.Ptr(false),
 						InsecureRegistries: []string{"good.io", "better.io"},
 					},
 					{
 						Kubecontext:        "this_is_a_context",
 						DefaultRepo:        "value",
-						MultiLevelRepo:     util.BoolPtr(true),
-						LocalCluster:       util.BoolPtr(true),
+						MultiLevelRepo:     util.Ptr(true),
+						LocalCluster:       util.Ptr(true),
 						InsecureRegistries: []string{"bad.io", "worse.io"},
 					},
 				},
@@ -75,8 +75,8 @@ insecure-registries:
 			cfg: &config.GlobalConfig{
 				Global: &config.ContextConfig{
 					DefaultRepo:        "default-repo-value",
-					MultiLevelRepo:     util.BoolPtr(true),
-					LocalCluster:       util.BoolPtr(true),
+					MultiLevelRepo:     util.Ptr(true),
+					LocalCluster:       util.Ptr(true),
 					InsecureRegistries: []string{"mediocre.io"},
 				},
 				ContextConfigs: []*config.ContextConfig{
@@ -99,8 +99,8 @@ insecure-registries:
 			cfg: &config.GlobalConfig{
 				Global: &config.ContextConfig{
 					DefaultRepo:        "default-repo-value",
-					MultiLevelRepo:     util.BoolPtr(true),
-					LocalCluster:       util.BoolPtr(true),
+					MultiLevelRepo:     util.Ptr(true),
+					LocalCluster:       util.Ptr(true),
 					InsecureRegistries: []string{"mediocre.io"},
 				},
 				ContextConfigs: []*config.ContextConfig{
@@ -128,8 +128,8 @@ kubeContexts:
 			cfg: &config.GlobalConfig{
 				Global: &config.ContextConfig{
 					DefaultRepo:        "default-repo-value",
-					MultiLevelRepo:     util.BoolPtr(true),
-					LocalCluster:       util.BoolPtr(true),
+					MultiLevelRepo:     util.Ptr(true),
+					LocalCluster:       util.Ptr(true),
 					InsecureRegistries: []string{"mediocre.io"},
 				},
 			},
diff --git a/cmd/skaffold/app/cmd/config/set_test.go b/cmd/skaffold/app/cmd/config/set_test.go
index 034ac293b..e84929864 100644
--- a/cmd/skaffold/app/cmd/config/set_test.go
+++ b/cmd/skaffold/app/cmd/config/set_test.go
@@ -71,7 +71,7 @@ func TestSetAndUnsetConfig(t *testing.T) {
 				ContextConfigs: []*config.ContextConfig{
 					{
 						Kubecontext:    "this_is_a_context",
-						MultiLevelRepo: util.BoolPtr(false),
+						MultiLevelRepo: util.Ptr(false),
 					},
 				},
 			},
@@ -92,7 +92,7 @@ func TestSetAndUnsetConfig(t *testing.T) {
 				ContextConfigs: []*config.ContextConfig{
 					{
 						Kubecontext:  "this_is_a_context",
-						LocalCluster: util.BoolPtr(false),
+						LocalCluster: util.Ptr(false),
 					},
 				},
 			},
@@ -140,7 +140,7 @@ func TestSetAndUnsetConfig(t *testing.T) {
 			global:      true,
 			expectedSetCfg: &config.GlobalConfig{
 				Global: &config.ContextConfig{
-					MultiLevelRepo: util.BoolPtr(true),
+					MultiLevelRepo: util.Ptr(true),
 				},
 				ContextConfigs: []*config.ContextConfig{},
 			},
@@ -156,7 +156,7 @@ func TestSetAndUnsetConfig(t *testing.T) {
 			global:      true,
 			expectedSetCfg: &config.GlobalConfig{
 				Global: &config.ContextConfig{
-					LocalCluster: util.BoolPtr(true),
+					LocalCluster: util.Ptr(true),
 				},
 				ContextConfigs: []*config.ContextConfig{},
 			},
@@ -192,7 +192,7 @@ func TestSetAndUnsetConfig(t *testing.T) {
 			value:       "true",
 			global:      true,
 			expectedSetCfg: &config.GlobalConfig{
-				Global:         &config.ContextConfig{UpdateCheck: util.BoolPtr(true)},
+				Global:         &config.ContextConfig{UpdateCheck: util.Ptr(true)},
 				ContextConfigs: []*config.ContextConfig{},
 			},
 			expectedUnsetCfg: &config.GlobalConfig{
@@ -209,7 +209,7 @@ func TestSetAndUnsetConfig(t *testing.T) {
 			expectedSetCfg: &config.GlobalConfig{
 				Global: &config.ContextConfig{
 					Survey: &config.SurveyConfig{
-						DisablePrompt: util.BoolPtr(true),
+						DisablePrompt: util.Ptr(true),
 					},
 				},
 				ContextConfigs: []*config.ContextConfig{},
@@ -228,7 +228,7 @@ func TestSetAndUnsetConfig(t *testing.T) {
 			expectedSetCfg: &config.GlobalConfig{
 				Global: &config.ContextConfig{
 					Survey: &config.SurveyConfig{
-						DisablePrompt: util.BoolPtr(false),
+						DisablePrompt: util.Ptr(false),
 					},
 				},
 				ContextConfigs: []*config.ContextConfig{},
@@ -251,7 +251,7 @@ func TestSetAndUnsetConfig(t *testing.T) {
 					{
 						Kubecontext: "this_is_a_context",
 						Survey: &config.SurveyConfig{
-							DisablePrompt: util.BoolPtr(false),
+							DisablePrompt: util.Ptr(false),
 						},
 					},
 				},
@@ -274,7 +274,7 @@ func TestSetAndUnsetConfig(t *testing.T) {
 				ContextConfigs: []*config.ContextConfig{
 					{
 						Kubecontext:     "this_is_a_context",
-						KindDisableLoad: util.BoolPtr(true),
+						KindDisableLoad: util.Ptr(true),
 					},
 				},
 			},
@@ -293,7 +293,7 @@ func TestSetAndUnsetConfig(t *testing.T) {
 			global:      true,
 			expectedSetCfg: &config.GlobalConfig{
 				Global: &config.ContextConfig{
-					KindDisableLoad: util.BoolPtr(true),
+					KindDisableLoad: util.Ptr(true),
 				},
 				ContextConfigs: []*config.ContextConfig{},
 			},
@@ -311,7 +311,7 @@ func TestSetAndUnsetConfig(t *testing.T) {
 				ContextConfigs: []*config.ContextConfig{
 					{
 						Kubecontext:    "this_is_a_context",
-						K3dDisableLoad: util.BoolPtr(true),
+						K3dDisableLoad: util.Ptr(true),
 					},
 				},
 			},
@@ -330,7 +330,7 @@ func TestSetAndUnsetConfig(t *testing.T) {
 			global:      true,
 			expectedSetCfg: &config.GlobalConfig{
 				Global: &config.ContextConfig{
-					K3dDisableLoad: util.BoolPtr(true),
+					K3dDisableLoad: util.Ptr(true),
 				},
 				ContextConfigs: []*config.ContextConfig{},
 			},
@@ -350,7 +350,7 @@ func TestSetAndUnsetConfig(t *testing.T) {
 				Global: &config.ContextConfig{
 					Survey: &config.SurveyConfig{
 						UserSurveys: []*config.UserSurvey{
-							{ID: "helm", Taken: util.BoolPtr(true)}}},
+							{ID: "helm", Taken: util.Ptr(true)}}},
 				},
 				ContextConfigs: []*config.ContextConfig{},
 			},
diff --git a/pkg/skaffold/build/builder_mux_test.go b/pkg/skaffold/build/builder_mux_test.go
index d5ca2f31a..05077afe7 100644
--- a/pkg/skaffold/build/builder_mux_test.go
+++ b/pkg/skaffold/build/builder_mux_test.go
@@ -40,7 +40,7 @@ func TestNewBuilderMux(t *testing.T) {
 		{
 			description: "only local builder",
 			pipelines: []latest.Pipeline{
-				{Build: latest.BuildConfig{BuildType: latest.BuildType{LocalBuild: &latest.LocalBuild{Concurrency: util.IntPtr(1)}}}},
+				{Build: latest.BuildConfig{BuildType: latest.BuildType{LocalBuild: &latest.LocalBuild{Concurrency: util.Ptr(1)}}}},
 			},
 			pipeBuilder:         newMockPipelineBuilder,
 			expectedBuilders:    []string{"local"},
@@ -65,8 +65,8 @@ func TestNewBuilderMux(t *testing.T) {
 		{
 			description: "min non-zero concurrency",
 			pipelines: []latest.Pipeline{
-				{Build: latest.BuildConfig{BuildType: latest.BuildType{LocalBuild: &latest.LocalBuild{Concurrency: util.IntPtr(0)}}}},
-				{Build: latest.BuildConfig{BuildType: latest.BuildType{LocalBuild: &latest.LocalBuild{Concurrency: util.IntPtr(3)}}}},
+				{Build: latest.BuildConfig{BuildType: latest.BuildType{LocalBuild: &latest.LocalBuild{Concurrency: util.Ptr(0)}}}},
+				{Build: latest.BuildConfig{BuildType: latest.BuildType{LocalBuild: &latest.LocalBuild{Concurrency: util.Ptr(3)}}}},
 				{Build: latest.BuildConfig{BuildType: latest.BuildType{Cluster: &latest.ClusterDetails{Concurrency: 2}}}},
 			},
 			pipeBuilder:         newMockPipelineBuilder,
@@ -111,8 +111,8 @@ func TestGetConcurrency(t *testing.T) {
 		{
 			description: "builder concurrency set to less than cli concurrency",
 			pbs: []PipelineBuilder{
-				&mockPipelineBuilder{concurrency: util.IntPtr(1), builderType: "local"},
-				&mockPipelineBuilder{concurrency: util.IntPtr(1), builderType: "local"},
+				&mockPipelineBuilder{concurrency: util.Ptr(1), builderType: "local"},
+				&mockPipelineBuilder{concurrency: util.Ptr(1), builderType: "local"},
 				&mockPipelineBuilder{concurrency: nil, builderType: "gcb"},
 			},
 			cliConcurrency:      2,
@@ -121,8 +121,8 @@ func TestGetConcurrency(t *testing.T) {
 		{
 			description: "builder concurrency set",
 			pbs: []PipelineBuilder{
-				&mockPipelineBuilder{concurrency: util.IntPtr(2), builderType: "local"},
-				&mockPipelineBuilder{concurrency: util.IntPtr(2), builderType: "local"},
+				&mockPipelineBuilder{concurrency: util.Ptr(2), builderType: "local"},
+				&mockPipelineBuilder{concurrency: util.Ptr(2), builderType: "local"},
 				&mockPipelineBuilder{concurrency: nil, builderType: "local"},
 			},
 			cliConcurrency:      -1,
@@ -132,8 +132,8 @@ func TestGetConcurrency(t *testing.T) {
 			description: "builder concurrency set to 0 and cli concurrency set to 1",
 			pbs: []PipelineBuilder{
 				// build all in parallel
-				&mockPipelineBuilder{concurrency: util.IntPtr(0), builderType: "local"},
-				&mockPipelineBuilder{concurrency: util.IntPtr(0), builderType: "gcb"},
+				&mockPipelineBuilder{concurrency: util.Ptr(0), builderType: "local"},
+				&mockPipelineBuilder{concurrency: util.Ptr(0), builderType: "gcb"},
 			},
 			cliConcurrency:      1,
 			expectedConcurrency: 1,
@@ -142,8 +142,8 @@ func TestGetConcurrency(t *testing.T) {
 			description: "builder concurrency set to 0 and cli concurrency unset",
 			pbs: []PipelineBuilder{
 				// build all in parallel
-				&mockPipelineBuilder{concurrency: util.IntPtr(0), builderType: "local"},
-				&mockPipelineBuilder{concurrency: util.IntPtr(0), builderType: "gcb"},
+				&mockPipelineBuilder{concurrency: util.Ptr(0), builderType: "local"},
+				&mockPipelineBuilder{concurrency: util.Ptr(0), builderType: "gcb"},
 			},
 			cliConcurrency:      -1,
 			expectedConcurrency: 0,
@@ -155,7 +155,7 @@ func TestGetConcurrency(t *testing.T) {
 				&mockPipelineBuilder{builderType: "local"},
 				&mockPipelineBuilder{builderType: "local"},
 				&mockPipelineBuilder{builderType: "local"},
-				&mockPipelineBuilder{concurrency: util.IntPtr(3), builderType: "local"},
+				&mockPipelineBuilder{concurrency: util.Ptr(3), builderType: "local"},
 			},
 			cliConcurrency:      -1,
 			expectedConcurrency: 3,
@@ -164,8 +164,8 @@ func TestGetConcurrency(t *testing.T) {
 			description: "builder concurrency set to default 0 for gcb",
 			pbs: []PipelineBuilder{
 				// build all in parallel
-				&mockPipelineBuilder{concurrency: util.IntPtr(0), builderType: "gcb"},
-				&mockPipelineBuilder{concurrency: util.IntPtr(0), builderType: "gcb"},
+				&mockPipelineBuilder{concurrency: util.Ptr(0), builderType: "gcb"},
+				&mockPipelineBuilder{concurrency: util.Ptr(0), builderType: "gcb"},
 			},
 			cliConcurrency:      -1,
 			expectedConcurrency: 0,
@@ -173,9 +173,9 @@ func TestGetConcurrency(t *testing.T) {
 		{
 			description: "min non-zero concurrency",
 			pbs: []PipelineBuilder{
-				&mockPipelineBuilder{concurrency: util.IntPtr(0), builderType: "local"},
-				&mockPipelineBuilder{concurrency: util.IntPtr(3), builderType: "gcb"},
-				&mockPipelineBuilder{concurrency: util.IntPtr(2), builderType: "gcb"},
+				&mockPipelineBuilder{concurrency: util.Ptr(0), builderType: "local"},
+				&mockPipelineBuilder{concurrency: util.Ptr(3), builderType: "gcb"},
+				&mockPipelineBuilder{concurrency: util.Ptr(2), builderType: "gcb"},
 			},
 			cliConcurrency:      -1,
 			expectedConcurrency: 2,
@@ -231,9 +231,9 @@ func newMockPipelineBuilder(p latest.Pipeline) (PipelineBuilder, error) {
 	case p.Build.BuildType.LocalBuild != nil:
 		return &mockPipelineBuilder{builderType: "local", concurrency: p.Build.LocalBuild.Concurrency}, nil
 	case p.Build.BuildType.Cluster != nil:
-		return &mockPipelineBuilder{builderType: "cluster", concurrency: util.IntPtr(p.Build.Cluster.Concurrency)}, nil
+		return &mockPipelineBuilder{builderType: "cluster", concurrency: util.Ptr(p.Build.Cluster.Concurrency)}, nil
 	case p.Build.BuildType.GoogleCloudBuild != nil:
-		return &mockPipelineBuilder{builderType: "gcb", concurrency: util.IntPtr(p.Build.GoogleCloudBuild.Concurrency)}, nil
+		return &mockPipelineBuilder{builderType: "gcb", concurrency: util.Ptr(p.Build.GoogleCloudBuild.Concurrency)}, nil
 	default:
 		return nil, errors.New("invalid config")
 	}
diff --git a/pkg/skaffold/build/buildpacks/build_test.go b/pkg/skaffold/build/buildpacks/build_test.go
index d6b31b25b..e057989cb 100644
--- a/pkg/skaffold/build/buildpacks/build_test.go
+++ b/pkg/skaffold/build/buildpacks/build_test.go
@@ -255,7 +255,7 @@ include = [
 		},
 		{
 			description: "dev mode",
-			artifact:    withSync(&latest.Sync{Auto: util.BoolPtr(true)}, buildpacksArtifact("another/builder", "another/run")),
+			artifact:    withSync(&latest.Sync{Auto: util.Ptr(true)}, buildpacksArtifact("another/builder", "another/run")),
 			tag:         "img:tag",
 			api:         &testutil.FakeAPIClient{},
 			resolver:    mockArtifactResolver{},
diff --git a/pkg/skaffold/build/cache/hash_test.go b/pkg/skaffold/build/cache/hash_test.go
index 9df01bfb1..426d69395 100644
--- a/pkg/skaffold/build/cache/hash_test.go
+++ b/pkg/skaffold/build/cache/hash_test.go
@@ -118,7 +118,7 @@ func TestGetHashForArtifact(t *testing.T) {
 				ArtifactType: latest.ArtifactType{
 					DockerArtifact: &latest.DockerArtifact{
 						BuildArgs: map[string]*string{
-							"key": util.StringPtr("value"),
+							"key": util.Ptr("value"),
 						},
 					},
 				},
@@ -302,7 +302,7 @@ func TestBuildArgs(t *testing.T) {
 				ArtifactType: latest.ArtifactType{
 					DockerArtifact: &latest.DockerArtifact{
 						DockerfilePath: Dockerfile,
-						BuildArgs:      map[string]*string{"one": util.StringPtr("1"), "two": util.StringPtr("2")},
+						BuildArgs:      map[string]*string{"one": util.Ptr("1"), "two": util.Ptr("2")},
 					},
 				},
 			}
@@ -314,14 +314,14 @@ func TestBuildArgs(t *testing.T) {
 			t.CheckDeepEqual(test.expected, actual)
 
 			// Change order of buildargs
-			artifact.ArtifactType.DockerArtifact.BuildArgs = map[string]*string{"two": util.StringPtr("2"), "one": util.StringPtr("1")}
+			artifact.ArtifactType.DockerArtifact.BuildArgs = map[string]*string{"two": util.Ptr("2"), "one": util.Ptr("1")}
 			actual, err = newArtifactHasher(nil, stubDependencyLister(nil), test.mode).hash(context.Background(), artifact, platform.Resolver{})
 
 			t.CheckNoError(err)
 			t.CheckDeepEqual(test.expected, actual)
 
 			// Change build args, get different hash
-			artifact.ArtifactType.DockerArtifact.BuildArgs = map[string]*string{"one": util.StringPtr("1")}
+			artifact.ArtifactType.DockerArtifact.BuildArgs = map[string]*string{"one": util.Ptr("1")}
 			actual, err = newArtifactHasher(nil, stubDependencyLister(nil), test.mode).hash(context.Background(), artifact, platform.Resolver{})
 
 			t.CheckNoError(err)
@@ -345,7 +345,7 @@ func TestBuildArgsEnvSubstitution(t *testing.T) {
 			Workspace: tmpDir.Path("."),
 			ArtifactType: latest.ArtifactType{
 				DockerArtifact: &latest.DockerArtifact{
-					BuildArgs:      map[string]*string{"env": util.StringPtr("${{.FOO}}")},
+					BuildArgs:      map[string]*string{"env": util.Ptr("${{.FOO}}")},
 					DockerfilePath: Dockerfile,
 				},
 			},
@@ -452,7 +452,7 @@ func TestHashBuildArgs(t *testing.T) {
 			artifactType: latest.ArtifactType{
 				DockerArtifact: &latest.DockerArtifact{
 					BuildArgs: map[string]*string{
-						"foo": util.StringPtr("bar"),
+						"foo": util.Ptr("bar"),
 					},
 				},
 			},
@@ -463,7 +463,7 @@ func TestHashBuildArgs(t *testing.T) {
 			artifactType: latest.ArtifactType{
 				DockerArtifact: &latest.DockerArtifact{
 					BuildArgs: map[string]*string{
-						"foo": util.StringPtr("bar"),
+						"foo": util.Ptr("bar"),
 					},
 				},
 			},
diff --git a/pkg/skaffold/build/cluster/pod_test.go b/pkg/skaffold/build/cluster/pod_test.go
index c9d03bf7a..b0035c16e 100644
--- a/pkg/skaffold/build/cluster/pod_test.go
+++ b/pkg/skaffold/build/cluster/pod_test.go
@@ -99,8 +99,8 @@ func TestKanikoArgs(t *testing.T) {
 				DockerfilePath: "Dockerfile",
 				BuildArgs: map[string]*string{
 					"nil_key":   nil,
-					"empty_key": util.StringPtr(""),
-					"value_key": util.StringPtr("value"),
+					"empty_key": util.Ptr(""),
+					"value_key": util.Ptr("value"),
 				},
 			},
 			expectedArgs: []string{
@@ -113,7 +113,7 @@ func TestKanikoArgs(t *testing.T) {
 			artifact: &latest.KanikoArtifact{
 				DockerfilePath: "Dockerfile",
 				BuildArgs: map[string]*string{
-					"invalid": util.StringPtr("{{Invalid"),
+					"invalid": util.Ptr("{{Invalid"),
 				},
 			},
 			shouldErr: true,
diff --git a/pkg/skaffold/build/custom/dependencies_test.go b/pkg/skaffold/build/custom/dependencies_test.go
index f1bd06c40..c57818390 100644
--- a/pkg/skaffold/build/custom/dependencies_test.go
+++ b/pkg/skaffold/build/custom/dependencies_test.go
@@ -43,7 +43,7 @@ func TestGetDependenciesDockerfile(t *testing.T) {
 			Dockerfile: &latest.DockerfileDependency{
 				Path: "Dockerfile",
 				BuildArgs: map[string]*string{
-					"file": util.StringPtr("foo"),
+					"file": util.Ptr("foo"),
 				},
 			},
 		},
diff --git a/pkg/skaffold/build/docker/docker_test.go b/pkg/skaffold/build/docker/docker_test.go
index a7c4ec1cd..7d6b283ec 100644
--- a/pkg/skaffold/build/docker/docker_test.go
+++ b/pkg/skaffold/build/docker/docker_test.go
@@ -65,7 +65,7 @@ func TestDockerCLIBuild(t *testing.T) {
 		},
 		{
 			description:   "buildkit",
-			localBuild:    latest.LocalBuild{UseBuildkit: util.BoolPtr(true)},
+			localBuild:    latest.LocalBuild{UseBuildkit: util.Ptr(true)},
 			wantDockerCLI: true,
 			expectedEnv:   []string{"KEY=VALUE", "DOCKER_BUILDKIT=1"},
 		},
@@ -78,14 +78,14 @@ func TestDockerCLIBuild(t *testing.T) {
 		},
 		{
 			description:   "buildkit and extra env",
-			localBuild:    latest.LocalBuild{UseBuildkit: util.BoolPtr(true)},
+			localBuild:    latest.LocalBuild{UseBuildkit: util.Ptr(true)},
 			wantDockerCLI: true,
 			extraEnv:      []string{"OTHER=VALUE"},
 			expectedEnv:   []string{"KEY=VALUE", "OTHER=VALUE", "DOCKER_BUILDKIT=1"},
 		},
 		{
 			description:   "env var collisions",
-			localBuild:    latest.LocalBuild{UseBuildkit: util.BoolPtr(true)},
+			localBuild:    latest.LocalBuild{UseBuildkit: util.Ptr(true)},
 			wantDockerCLI: true,
 			extraEnv:      []string{"KEY=OTHER_VALUE", "DOCKER_BUILDKIT=0"},
 			// DOCKER_BUILDKIT should be overridden
@@ -242,7 +242,7 @@ func TestDockerCLICheckCacheFromArgs(t *testing.T) {
 			)
 			t.Override(&util.DefaultExecCommand, mockCmd)
 
-			builder := NewArtifactBuilder(fakeLocalDaemonWithExtraEnv([]string{}), mockConfig{}, true, util.BoolPtr(false), false, mockArtifactResolver{make(map[string]string)}, nil)
+			builder := NewArtifactBuilder(fakeLocalDaemonWithExtraEnv([]string{}), mockConfig{}, true, util.Ptr(false), false, mockArtifactResolver{make(map[string]string)}, nil)
 			_, err := builder.Build(context.Background(), io.Discard, &a, test.tag, platform.Matcher{})
 			t.CheckNoError(err)
 		})
diff --git a/pkg/skaffold/build/gcb/docker_test.go b/pkg/skaffold/build/gcb/docker_test.go
index b29cc30e9..adb9213de 100644
--- a/pkg/skaffold/build/gcb/docker_test.go
+++ b/pkg/skaffold/build/gcb/docker_test.go
@@ -46,7 +46,7 @@ func TestDockerBuildSpec(t *testing.T) {
 					DockerArtifact: &latest.DockerArtifact{
 						DockerfilePath: "Dockerfile",
 						BuildArgs: map[string]*string{
-							"arg1": util.StringPtr("value1"),
+							"arg1": util.Ptr("value1"),
 							"arg2": nil,
 						},
 					},
@@ -80,7 +80,7 @@ func TestDockerBuildSpec(t *testing.T) {
 					DockerArtifact: &latest.DockerArtifact{
 						DockerfilePath: "Dockerfile",
 						BuildArgs: map[string]*string{
-							"arg1": util.StringPtr("value1"),
+							"arg1": util.Ptr("value1"),
 							"arg2": nil,
 						},
 					},
@@ -141,7 +141,7 @@ func TestDockerBuildSpec(t *testing.T) {
 					DockerArtifact: &latest.DockerArtifact{
 						DockerfilePath: "Dockerfile",
 						BuildArgs: map[string]*string{
-							"arg1": util.StringPtr("value1"),
+							"arg1": util.Ptr("value1"),
 							"arg2": nil,
 						},
 					},
diff --git a/pkg/skaffold/build/gcb/kaniko_test.go b/pkg/skaffold/build/gcb/kaniko_test.go
index 995eef29d..38b9114b1 100644
--- a/pkg/skaffold/build/gcb/kaniko_test.go
+++ b/pkg/skaffold/build/gcb/kaniko_test.go
@@ -52,7 +52,7 @@ func TestKanikoBuildSpec(t *testing.T) {
 			artifact: &latest.KanikoArtifact{
 				DockerfilePath: "Dockerfile",
 				BuildArgs: map[string]*string{
-					"arg1": util.StringPtr("value1"),
+					"arg1": util.Ptr("value1"),
 					"arg2": nil,
 				},
 			},
@@ -219,8 +219,8 @@ func TestKanikoBuildSpec(t *testing.T) {
 			artifact: &latest.KanikoArtifact{
 				DockerfilePath: "Dockerfile",
 				RegistryCertificate: map[string]*string{
-					"s1.registry.url": util.StringPtr("/etc/certs/certificate1.cert"),
-					"s2.registry.url": util.StringPtr("/etc/certs/certificate2.cert"),
+					"s1.registry.url": util.Ptr("/etc/certs/certificate1.cert"),
+					"s2.registry.url": util.Ptr("/etc/certs/certificate2.cert"),
 				},
 			},
 			expectedArgs: []string{
@@ -388,7 +388,7 @@ func TestKanikoBuildSpec(t *testing.T) {
 			artifact: &latest.KanikoArtifact{
 				DockerfilePath: "Dockerfile",
 				Label: map[string]*string{
-					"label1": util.StringPtr("value1"),
+					"label1": util.Ptr("value1"),
 					"label2": nil,
 				},
 			},
diff --git a/pkg/skaffold/build/kaniko/args_test.go b/pkg/skaffold/build/kaniko/args_test.go
index b89fee822..8743c1595 100644
--- a/pkg/skaffold/build/kaniko/args_test.go
+++ b/pkg/skaffold/build/kaniko/args_test.go
@@ -45,7 +45,7 @@ func TestArgs(t *testing.T) {
 			artifact: &latest.KanikoArtifact{
 				DockerfilePath: "dir/Dockerfile",
 				BuildArgs: map[string]*string{
-					"arg1": util.StringPtr("value1"),
+					"arg1": util.Ptr("value1"),
 					"arg2": nil,
 				},
 			},
@@ -214,8 +214,8 @@ func TestArgs(t *testing.T) {
 			artifact: &latest.KanikoArtifact{
 				DockerfilePath: "dir/Dockerfile",
 				RegistryCertificate: map[string]*string{
-					"s1.registry.url": util.StringPtr("/etc/certs/certificate1.cert"),
-					"s2.registry.url": util.StringPtr("/etc/certs/certificate2.cert"),
+					"s1.registry.url": util.Ptr("/etc/certs/certificate1.cert"),
+					"s2.registry.url": util.Ptr("/etc/certs/certificate2.cert"),
 				},
 			},
 			expectedArgs: []string{
@@ -397,7 +397,7 @@ func TestArgs(t *testing.T) {
 			artifact: &latest.KanikoArtifact{
 				DockerfilePath: "dir/Dockerfile",
 				Label: map[string]*string{
-					"label1": util.StringPtr("value1"),
+					"label1": util.Ptr("value1"),
 					"label2": nil,
 				},
 			},
diff --git a/pkg/skaffold/build/local/local_test.go b/pkg/skaffold/build/local/local_test.go
index b9bc45b17..63a095286 100644
--- a/pkg/skaffold/build/local/local_test.go
+++ b/pkg/skaffold/build/local/local_test.go
@@ -240,7 +240,7 @@ func TestLocalRun(t *testing.T) {
 				}}})
 
 			builder, err := NewBuilder(context.Background(), &mockBuilderContext{artifactStore: build.NewArtifactStore()}, &latest.LocalBuild{
-				Push:        util.BoolPtr(test.pushImages),
+				Push:        util.Ptr(test.pushImages),
 				Concurrency: &constants.DefaultLocalConcurrency,
 			})
 			t.CheckNoError(err)
@@ -291,7 +291,7 @@ func TestNewBuilder(t *testing.T) {
 			},
 			cluster: config.Cluster{PushImages: true},
 			localBuild: latest.LocalBuild{
-				Push: util.BoolPtr(false),
+				Push: util.Ptr(false),
 			},
 			shouldErr:    false,
 			expectedPush: false,
@@ -302,7 +302,7 @@ func TestNewBuilder(t *testing.T) {
 				return dummyDaemon, nil
 			},
 			cluster:      config.Cluster{PushImages: true},
-			pushFlag:     config.NewBoolOrUndefined(util.BoolPtr(false)),
+			pushFlag:     config.NewBoolOrUndefined(util.Ptr(false)),
 			shouldErr:    false,
 			expectedPush: false,
 		},
@@ -311,9 +311,9 @@ func TestNewBuilder(t *testing.T) {
 			localDockerFn: func(context.Context, docker.Config) (docker.LocalDaemon, error) {
 				return dummyDaemon, nil
 			},
-			pushFlag: config.NewBoolOrUndefined(util.BoolPtr(false)),
+			pushFlag: config.NewBoolOrUndefined(util.Ptr(false)),
 			localBuild: latest.LocalBuild{
-				Push: util.BoolPtr(true),
+				Push: util.Ptr(true),
 			},
 			shouldErr:    false,
 			expectedPush: false,
diff --git a/pkg/skaffold/config/types_test.go b/pkg/skaffold/config/types_test.go
index 1542f62f6..00786a470 100644
--- a/pkg/skaffold/config/types_test.go
+++ b/pkg/skaffold/config/types_test.go
@@ -62,12 +62,12 @@ func TestStringOrUndefined(t *testing.T) {
 		{
 			description: "set",
 			args:        []string{"--flag=value"},
-			expected:    util.StringPtr("value"),
+			expected:    util.Ptr("value"),
 		},
 		{
 			description: "empty",
 			args:        []string{"--flag="},
-			expected:    util.StringPtr(""),
+			expected:    util.Ptr(""),
 		},
 	}
 	for _, test := range tests {
@@ -129,12 +129,12 @@ func TestBoolOrUndefined(t *testing.T) {
 		{
 			description: "true",
 			args:        []string{"--bool-flag=true"},
-			expected:    util.BoolPtr(true),
+			expected:    util.Ptr(true),
 		},
 		{
 			description: "false",
 			args:        []string{"--bool-flag=false"},
-			expected:    util.BoolPtr(false),
+			expected:    util.Ptr(false),
 		},
 	}
 	for _, test := range tests {
@@ -194,17 +194,17 @@ func TestIntOrUndefined(t *testing.T) {
 		{
 			description: "0",
 			args:        []string{"--int-flag=0"},
-			expected:    util.IntPtr(0),
+			expected:    util.Ptr(0),
 		},
 		{
 			description: "1",
 			args:        []string{"--int-flag=1"},
-			expected:    util.IntPtr(1),
+			expected:    util.Ptr(1),
 		},
 		{
 			description: "-1",
 			args:        []string{"--int-flag=-1"},
-			expected:    util.IntPtr(-1),
+			expected:    util.Ptr(-1),
 		},
 	}
 	for _, test := range tests {
diff --git a/pkg/skaffold/config/util_test.go b/pkg/skaffold/config/util_test.go
index 016094ab6..a1d9373a3 100644
--- a/pkg/skaffold/config/util_test.go
+++ b/pkg/skaffold/config/util_test.go
@@ -42,15 +42,15 @@ func TestReadConfig(t *testing.T) {
 	baseConfig := &GlobalConfig{
 		Global: &ContextConfig{
 			DefaultRepo:    "test-repository",
-			MultiLevelRepo: util.BoolPtr(false),
+			MultiLevelRepo: util.Ptr(false),
 		},
 		ContextConfigs: []*ContextConfig{
 			{
 				Kubecontext:        "test-context",
 				InsecureRegistries: []string{"bad.io", "worse.io"},
-				LocalCluster:       util.BoolPtr(true),
+				LocalCluster:       util.Ptr(true),
 				DefaultRepo:        "context-local-repository",
-				MultiLevelRepo:     util.BoolPtr(true),
+				MultiLevelRepo:     util.Ptr(true),
 			},
 		},
 	}
@@ -113,15 +113,15 @@ func Test_getConfigForKubeContextWithGlobalDefaults(t *testing.T) {
 	sampleConfig1 := &ContextConfig{
 		Kubecontext:        someKubeContext,
 		InsecureRegistries: []string{"bad.io", "worse.io"},
-		LocalCluster:       util.BoolPtr(true),
+		LocalCluster:       util.Ptr(true),
 		DefaultRepo:        "my-private-registry",
-		MultiLevelRepo:     util.BoolPtr(true),
+		MultiLevelRepo:     util.Ptr(true),
 	}
 	sampleConfig2 := &ContextConfig{
 		Kubecontext:    "another_context",
-		LocalCluster:   util.BoolPtr(false),
+		LocalCluster:   util.Ptr(false),
 		DefaultRepo:    "my-public-registry",
-		MultiLevelRepo: util.BoolPtr(false),
+		MultiLevelRepo: util.Ptr(false),
 	}
 
 	tests := []struct {
@@ -135,9 +135,9 @@ func Test_getConfigForKubeContextWithGlobalDefaults(t *testing.T) {
 			cfg: &GlobalConfig{
 				Global: &ContextConfig{
 					InsecureRegistries: []string{"mediocre.io"},
-					LocalCluster:       util.BoolPtr(true),
+					LocalCluster:       util.Ptr(true),
 					DefaultRepo:        "my-private-registry",
-					MultiLevelRepo:     util.BoolPtr(true),
+					MultiLevelRepo:     util.Ptr(true),
 				},
 				ContextConfigs: []*ContextConfig{
 					{
@@ -148,9 +148,9 @@ func Test_getConfigForKubeContextWithGlobalDefaults(t *testing.T) {
 			},
 			expectedConfig: &ContextConfig{
 				InsecureRegistries: []string{"mediocre.io"},
-				LocalCluster:       util.BoolPtr(true),
+				LocalCluster:       util.Ptr(true),
 				DefaultRepo:        "my-private-registry",
-				MultiLevelRepo:     util.BoolPtr(true),
+				MultiLevelRepo:     util.Ptr(true),
 			},
 		},
 		{
@@ -196,9 +196,9 @@ func Test_getConfigForKubeContextWithGlobalDefaults(t *testing.T) {
 			},
 			expectedConfig: &ContextConfig{
 				Kubecontext:    someKubeContext,
-				LocalCluster:   util.BoolPtr(false),
+				LocalCluster:   util.Ptr(false),
 				DefaultRepo:    "my-public-registry",
-				MultiLevelRepo: util.BoolPtr(false),
+				MultiLevelRepo: util.Ptr(false),
 			},
 		},
 		{
@@ -207,9 +207,9 @@ func Test_getConfigForKubeContextWithGlobalDefaults(t *testing.T) {
 			cfg:         &GlobalConfig{Global: sampleConfig2},
 			expectedConfig: &ContextConfig{
 				Kubecontext:    someKubeContext,
-				LocalCluster:   util.BoolPtr(false),
+				LocalCluster:   util.Ptr(false),
 				DefaultRepo:    "my-public-registry",
-				MultiLevelRepo: util.BoolPtr(false),
+				MultiLevelRepo: util.Ptr(false),
 			},
 		},
 		{
@@ -253,12 +253,12 @@ func TestIsUpdateCheckEnabled(t *testing.T) {
 		},
 		{
 			description: "config update-check is true",
-			cfg:         &ContextConfig{UpdateCheck: util.BoolPtr(true)},
+			cfg:         &ContextConfig{UpdateCheck: util.Ptr(true)},
 			expected:    true,
 		},
 		{
 			description: "config update-check is false",
-			cfg:         &ContextConfig{UpdateCheck: util.BoolPtr(false)},
+			cfg:         &ContextConfig{UpdateCheck: util.Ptr(false)},
 		},
 		{
 			description: "config is nil",
@@ -318,12 +318,12 @@ func TestGetCluster(t *testing.T) {
 		},
 		{
 			description: "kind with local-cluster=false",
-			cfg:         &ContextConfig{Kubecontext: "kind-other", LocalCluster: util.BoolPtr(false)},
+			cfg:         &ContextConfig{Kubecontext: "kind-other", LocalCluster: util.Ptr(false)},
 			expected:    Cluster{Local: false, LoadImages: false, PushImages: true},
 		},
 		{
 			description: "kind with kind-disable-load=true",
-			cfg:         &ContextConfig{Kubecontext: "kind-other", KindDisableLoad: util.BoolPtr(true)},
+			cfg:         &ContextConfig{Kubecontext: "kind-other", KindDisableLoad: util.Ptr(true)},
 			expected:    Cluster{Local: true, LoadImages: false, PushImages: true},
 		},
 		{
@@ -338,12 +338,12 @@ func TestGetCluster(t *testing.T) {
 		},
 		{
 			description: "k3d with local-cluster=false",
-			cfg:         &ContextConfig{Kubecontext: "k3d-k3s-default", LocalCluster: util.BoolPtr(false)},
+			cfg:         &ContextConfig{Kubecontext: "k3d-k3s-default", LocalCluster: util.Ptr(false)},
 			expected:    Cluster{Local: false, LoadImages: false, PushImages: true},
 		},
 		{
 			description: "k3d with disable-load=true",
-			cfg:         &ContextConfig{Kubecontext: "k3d-k3s-default", K3dDisableLoad: util.BoolPtr(true)},
+			cfg:         &ContextConfig{Kubecontext: "k3d-k3s-default", K3dDisableLoad: util.Ptr(true)},
 			expected:    Cluster{Local: true, LoadImages: false, PushImages: true},
 		},
 		{
@@ -363,7 +363,7 @@ func TestGetCluster(t *testing.T) {
 		},
 		{
 			description: "generic cluster with local-cluster=true",
-			cfg:         &ContextConfig{Kubecontext: "some-cluster", LocalCluster: util.BoolPtr(true)},
+			cfg:         &ContextConfig{Kubecontext: "some-cluster", LocalCluster: util.Ptr(true)},
 			expected:    Cluster{Local: true, LoadImages: false, PushImages: false},
 		},
 		{
@@ -571,7 +571,7 @@ func TestGetDefaultRepo(t *testing.T) {
 		{
 			description:  "from cli",
 			cfg:          &ContextConfig{},
-			cliValue:     util.StringPtr("default/repo"),
+			cliValue:     util.Ptr("default/repo"),
 			expectedRepo: "default/repo",
 		},
 		{
@@ -583,7 +583,7 @@ func TestGetDefaultRepo(t *testing.T) {
 		{
 			description:  "cancel global config with cli",
 			cfg:          &ContextConfig{DefaultRepo: "global/repo"},
-			cliValue:     util.StringPtr(""),
+			cliValue:     util.Ptr(""),
 			expectedRepo: "",
 		},
 	}
@@ -612,8 +612,8 @@ func TestGetMultiLevelRepo(t *testing.T) {
 		},
 		{
 			description:   "from global config",
-			cfg:           &ContextConfig{MultiLevelRepo: util.BoolPtr(true)},
-			expectedValue: util.BoolPtr(true),
+			cfg:           &ContextConfig{MultiLevelRepo: util.Ptr(true)},
+			expectedValue: util.Ptr(true),
 		},
 	}
 	for _, test := range tests {
@@ -856,7 +856,7 @@ global:
 kubeContexts: []`,
 			expectedCfg: &GlobalConfig{
 				Global: &ContextConfig{
-					UpdateCheck: util.BoolPtr(false),
+					UpdateCheck: util.Ptr(false),
 				},
 				ContextConfigs: []*ContextConfig{},
 			},
@@ -871,7 +871,7 @@ global:
 kubeContexts: []`,
 			expectedCfg: &GlobalConfig{
 				Global: &ContextConfig{
-					UpdateCheck: util.BoolPtr(false),
+					UpdateCheck: util.Ptr(false),
 					UpdateCheckConfig: &UpdateConfig{
 						LastPrompted: "some date"},
 				},
@@ -941,7 +941,7 @@ func TestUpdateUserSurveyTaken(t *testing.T) {
 			expectedCfg: &GlobalConfig{
 				Global: &ContextConfig{
 					Survey: &SurveyConfig{UserSurveys: []*UserSurvey{
-						{ID: "foo", Taken: util.BoolPtr(true)},
+						{ID: "foo", Taken: util.Ptr(true)},
 					}}},
 				ContextConfigs: []*ContextConfig{},
 			},
@@ -960,8 +960,8 @@ kubeContexts: []`,
 				Global: &ContextConfig{
 					Survey: &SurveyConfig{
 						UserSurveys: []*UserSurvey{
-							{ID: "foo1", Taken: util.BoolPtr(true)},
-							{ID: "foo2", Taken: util.BoolPtr(true)},
+							{ID: "foo1", Taken: util.Ptr(true)},
+							{ID: "foo2", Taken: util.Ptr(true)},
 						}}},
 				ContextConfigs: []*ContextConfig{},
 			},
@@ -980,7 +980,7 @@ kubeContexts: []`,
 				Global: &ContextConfig{
 					Survey: &SurveyConfig{
 						UserSurveys: []*UserSurvey{
-							{ID: "foo", Taken: util.BoolPtr(true)},
+							{ID: "foo", Taken: util.Ptr(true)},
 						}}},
 				ContextConfigs: []*ContextConfig{},
 			},
diff --git a/pkg/skaffold/deploy/component/kubernetes/monitor_test.go b/pkg/skaffold/deploy/component/kubernetes/monitor_test.go
index 3fec54824..bae226e7c 100644
--- a/pkg/skaffold/deploy/component/kubernetes/monitor_test.go
+++ b/pkg/skaffold/deploy/component/kubernetes/monitor_test.go
@@ -53,11 +53,11 @@ func TestGetMonitor(t *testing.T) {
 		},
 		{
 			description: "statusCheck parameter set to true",
-			statusCheck: util.BoolPtr(true),
+			statusCheck: util.Ptr(true),
 		},
 		{
 			description: "statusCheck parameter set to false",
-			statusCheck: util.BoolPtr(false),
+			statusCheck: util.Ptr(false),
 			isNoop:      true,
 		},
 	}
diff --git a/pkg/skaffold/docker/build_args_test.go b/pkg/skaffold/docker/build_args_test.go
index 927186d52..8db455d0c 100644
--- a/pkg/skaffold/docker/build_args_test.go
+++ b/pkg/skaffold/docker/build_args_test.go
@@ -42,16 +42,16 @@ ARG foo3
 ARG SKAFFOLD_GO_GCFLAGS
 FROM bar1`,
 			buildArgs: map[string]*string{
-				"foo1": util.StringPtr("one"),
-				"foo2": util.StringPtr("two"),
-				"foo3": util.StringPtr("three"),
+				"foo1": util.Ptr("one"),
+				"foo2": util.Ptr("two"),
+				"foo3": util.Ptr("three"),
 			},
 			mode: config.RunModes.Debug,
 			expected: map[string]*string{
-				"SKAFFOLD_GO_GCFLAGS": util.StringPtr("all=-N -l"),
-				"foo1":                util.StringPtr("one"),
-				"foo2":                util.StringPtr("two"),
-				"foo3":                util.StringPtr("three"),
+				"SKAFFOLD_GO_GCFLAGS": util.Ptr("all=-N -l"),
+				"foo1":                util.Ptr("one"),
+				"foo2":                util.Ptr("two"),
+				"foo3":                util.Ptr("three"),
 			},
 		},
 		{
@@ -62,15 +62,15 @@ ARG SKAFFOLD_GO_GCFLAGS
 FROM bar1`,
 			mode: config.RunModes.Debug,
 			buildArgs: map[string]*string{
-				"foo1": util.StringPtr("one"),
-				"foo2": util.StringPtr("two"),
-				"foo3": util.StringPtr("three"),
+				"foo1": util.Ptr("one"),
+				"foo2": util.Ptr("two"),
+				"foo3": util.Ptr("three"),
 			},
 			expected: map[string]*string{
-				"SKAFFOLD_GO_GCFLAGS": util.StringPtr("all=-N -l"),
-				"foo1":                util.StringPtr("one"),
-				"foo2":                util.StringPtr("two"),
-				"foo3":                util.StringPtr("three"),
+				"SKAFFOLD_GO_GCFLAGS": util.Ptr("all=-N -l"),
+				"foo1":                util.Ptr("one"),
+				"foo2":                util.Ptr("two"),
+				"foo3":                util.Ptr("three"),
 			},
 		},
 		{
@@ -82,20 +82,20 @@ ARG SKAFFOLD_GO_GCFLAGS
 FROM bar1`,
 			mode: config.RunModes.Debug,
 			buildArgs: map[string]*string{
-				"foo1": util.StringPtr("one"),
-				"foo2": util.StringPtr("two"),
-				"foo3": util.StringPtr("three"),
+				"foo1": util.Ptr("one"),
+				"foo2": util.Ptr("two"),
+				"foo3": util.Ptr("three"),
 			},
 			extra: map[string]*string{
-				"foo4": util.StringPtr("four"),
-				"foo5": util.StringPtr("five"),
+				"foo4": util.Ptr("four"),
+				"foo5": util.Ptr("five"),
 			},
 			expected: map[string]*string{
-				"SKAFFOLD_GO_GCFLAGS": util.StringPtr("all=-N -l"),
-				"foo1":                util.StringPtr("one"),
-				"foo2":                util.StringPtr("two"),
-				"foo3":                util.StringPtr("three"),
-				"foo4":                util.StringPtr("four"),
+				"SKAFFOLD_GO_GCFLAGS": util.Ptr("all=-N -l"),
+				"foo1":                util.Ptr("one"),
+				"foo2":                util.Ptr("two"),
+				"foo3":                util.Ptr("three"),
+				"foo4":                util.Ptr("four"),
 			},
 		},
 		{
@@ -104,15 +104,15 @@ FROM bar1`,
 ARG foo3
 FROM bar1`,
 			buildArgs: map[string]*string{
-				"foo1": util.StringPtr("one"),
-				"foo2": util.StringPtr("two"),
-				"foo3": util.StringPtr("three"),
+				"foo1": util.Ptr("one"),
+				"foo2": util.Ptr("two"),
+				"foo3": util.Ptr("three"),
 			},
 			mode: config.RunModes.Debug,
 			expected: map[string]*string{
-				"foo1": util.StringPtr("one"),
-				"foo2": util.StringPtr("two"),
-				"foo3": util.StringPtr("three"),
+				"foo1": util.Ptr("one"),
+				"foo2": util.Ptr("two"),
+				"foo3": util.Ptr("three"),
 			},
 		},
 		{
@@ -125,16 +125,16 @@ ARG foo2
 FROM bar2
 ARG foo3`,
 			buildArgs: map[string]*string{
-				"foo1": util.StringPtr("one"),
-				"foo2": util.StringPtr("two"),
-				"foo3": util.StringPtr("three"),
+				"foo1": util.Ptr("one"),
+				"foo2": util.Ptr("two"),
+				"foo3": util.Ptr("three"),
 			},
 			mode: config.RunModes.Debug,
 			expected: map[string]*string{
-				"SKAFFOLD_GO_GCFLAGS": util.StringPtr("all=-N -l"),
-				"foo1":                util.StringPtr("one"),
-				"foo2":                util.StringPtr("two"),
-				"foo3":                util.StringPtr("three"),
+				"SKAFFOLD_GO_GCFLAGS": util.Ptr("all=-N -l"),
+				"foo1":                util.Ptr("one"),
+				"foo2":                util.Ptr("two"),
+				"foo3":                util.Ptr("three"),
 			},
 		},
 		{
@@ -147,17 +147,17 @@ ARG foo2
 FROM bar2
 ARG foo3`,
 			buildArgs: map[string]*string{
-				"foo1": util.StringPtr("one"),
-				"foo2": util.StringPtr("two"),
-				"foo3": util.StringPtr("three"),
+				"foo1": util.Ptr("one"),
+				"foo2": util.Ptr("two"),
+				"foo3": util.Ptr("three"),
 			},
 			mode: config.RunModes.Debug,
 			expected: map[string]*string{
-				"SKAFFOLD_RUN_MODE":   util.StringPtr("debug"),
-				"SKAFFOLD_GO_GCFLAGS": util.StringPtr("all=-N -l"),
-				"foo1":                util.StringPtr("one"),
-				"foo2":                util.StringPtr("two"),
-				"foo3":                util.StringPtr("three"),
+				"SKAFFOLD_RUN_MODE":   util.Ptr("debug"),
+				"SKAFFOLD_GO_GCFLAGS": util.Ptr("all=-N -l"),
+				"foo1":                util.Ptr("one"),
+				"foo2":                util.Ptr("two"),
+				"foo3":                util.Ptr("three"),
 			},
 		},
 		{
@@ -168,16 +168,16 @@ ARG foo3
 ARG SKAFFOLD_RUN_MODE
 FROM bar1`,
 			buildArgs: map[string]*string{
-				"foo1": util.StringPtr("one"),
-				"foo2": util.StringPtr("two"),
-				"foo3": util.StringPtr("three"),
+				"foo1": util.Ptr("one"),
+				"foo2": util.Ptr("two"),
+				"foo3": util.Ptr("three"),
 			},
 			mode: config.RunModes.Dev,
 			expected: map[string]*string{
-				"SKAFFOLD_RUN_MODE": util.StringPtr("dev"),
-				"foo1":              util.StringPtr("one"),
-				"foo2":              util.StringPtr("two"),
-				"foo3":              util.StringPtr("three"),
+				"SKAFFOLD_RUN_MODE": util.Ptr("dev"),
+				"foo1":              util.Ptr("one"),
+				"foo2":              util.Ptr("two"),
+				"foo3":              util.Ptr("three"),
 			},
 		},
 		{
@@ -186,15 +186,15 @@ FROM bar1`,
 ARG foo3
 FROM bar1`,
 			buildArgs: map[string]*string{
-				"foo1": util.StringPtr("one"),
-				"foo2": util.StringPtr("two"),
-				"foo3": util.StringPtr("three"),
+				"foo1": util.Ptr("one"),
+				"foo2": util.Ptr("two"),
+				"foo3": util.Ptr("three"),
 			},
 			mode: config.RunModes.Dev,
 			expected: map[string]*string{
-				"foo1": util.StringPtr("one"),
-				"foo2": util.StringPtr("two"),
-				"foo3": util.StringPtr("three"),
+				"foo1": util.Ptr("one"),
+				"foo2": util.Ptr("two"),
+				"foo3": util.Ptr("three"),
 			},
 		},
 	}
@@ -228,7 +228,7 @@ func TestCreateBuildArgsFromArtifacts(t *testing.T) {
 			description: "can resolve artifacts",
 			r:           mockArtifactResolver{m: map[string]string{"img1": "tag1", "img2": "tag2", "img3": "tag3", "img4": "tag4"}},
 			deps:        []*latest.ArtifactDependency{{ImageName: "img3", Alias: "alias3"}, {ImageName: "img4", Alias: "alias4"}},
-			args:        map[string]*string{"alias3": util.StringPtr("tag3"), "alias4": util.StringPtr("tag4")},
+			args:        map[string]*string{"alias3": util.Ptr("tag3"), "alias4": util.Ptr("tag4")},
 		},
 		{
 			description: "cannot resolve artifacts",
@@ -252,8 +252,8 @@ func TestBuildArgTemplating(t *testing.T) {
 	}
 
 	args := map[string]*string{
-		"MY_KEY":    util.StringPtr("{{ .MY_KEY}}"),
-		"SO_SECRET": util.StringPtr("{{ .SO_SECRET}}"),
+		"MY_KEY":    util.Ptr("{{ .MY_KEY}}"),
+		"SO_SECRET": util.Ptr("{{ .SO_SECRET}}"),
 	}
 
 	dockerFile := `
diff --git a/pkg/skaffold/docker/default_repo_test.go b/pkg/skaffold/docker/default_repo_test.go
index 19753d74e..3e3def49e 100644
--- a/pkg/skaffold/docker/default_repo_test.go
+++ b/pkg/skaffold/docker/default_repo_test.go
@@ -42,7 +42,7 @@ func TestImageReplaceDefaultRepo(t *testing.T) {
 			description:    "basic GCR concatenation without multi-level",
 			image:          "gcr.io/some/registry",
 			defaultRepo:    "gcr.io/default",
-			multiLevelRepo: util.BoolPtr(false),
+			multiLevelRepo: util.Ptr(false),
 			expectedImage:  "gcr.io/default/gcr.io/some/registry",
 		},
 		{
@@ -55,7 +55,7 @@ func TestImageReplaceDefaultRepo(t *testing.T) {
 			description:    "basic AR concatenation without multi-level",
 			image:          "github.com/org/app",
 			defaultRepo:    "us-central1-docker.pkg.dev/default",
-			multiLevelRepo: util.BoolPtr(false),
+			multiLevelRepo: util.Ptr(false),
 			expectedImage:  "us-central1-docker.pkg.dev/default/github.com/org/app",
 		},
 		{
@@ -91,7 +91,7 @@ func TestImageReplaceDefaultRepo(t *testing.T) {
 			description:    "aws multi-level",
 			image:          "gcr.io/some/registry",
 			defaultRepo:    "aws_account_id.dkr.ecr.region.amazonaws.com",
-			multiLevelRepo: util.BoolPtr(true),
+			multiLevelRepo: util.Ptr(true),
 			expectedImage:  "aws_account_id.dkr.ecr.region.amazonaws.com/gcr.io/some/registry",
 		},
 		{
@@ -128,7 +128,7 @@ func TestImageReplaceDefaultRepo(t *testing.T) {
 			description:    "ko multi-level not with GCR",
 			image:          "ko://example.com/cmd/app",
 			defaultRepo:    "myrepo",
-			multiLevelRepo: util.BoolPtr(true),
+			multiLevelRepo: util.Ptr(true),
 			expectedImage:  "myrepo/example.com/cmd/app",
 		},
 		{
diff --git a/pkg/skaffold/docker/dependencies_test.go b/pkg/skaffold/docker/dependencies_test.go
index bdd91f79e..083855146 100644
--- a/pkg/skaffold/docker/dependencies_test.go
+++ b/pkg/skaffold/docker/dependencies_test.go
@@ -459,28 +459,28 @@ func TestGetDependencies(t *testing.T) {
 			description: "build args",
 			dockerfile:  copyServerGoBuildArg,
 			workspace:   ".",
-			buildArgs:   map[string]*string{"FOO": util.StringPtr("server.go")},
+			buildArgs:   map[string]*string{"FOO": util.Ptr("server.go")},
 			expected:    []string{"Dockerfile", "server.go"},
 		},
 		{
 			description: "build args with same prefix",
 			dockerfile:  copyWorkerGoBuildArgSamePrefix,
 			workspace:   ".",
-			buildArgs:   map[string]*string{"FOO2": util.StringPtr("worker.go")},
+			buildArgs:   map[string]*string{"FOO2": util.Ptr("worker.go")},
 			expected:    []string{"Dockerfile", "worker.go"},
 		},
 		{
 			description: "build args with curly braces",
 			dockerfile:  copyServerGoBuildArgCurlyBraces,
 			workspace:   ".",
-			buildArgs:   map[string]*string{"FOO": util.StringPtr("server.go")},
+			buildArgs:   map[string]*string{"FOO": util.Ptr("server.go")},
 			expected:    []string{"Dockerfile", "server.go"},
 		},
 		{
 			description: "build args with extra whitespace",
 			dockerfile:  copyServerGoBuildArgExtraWhitespace,
 			workspace:   ".",
-			buildArgs:   map[string]*string{"FOO": util.StringPtr("server.go")},
+			buildArgs:   map[string]*string{"FOO": util.Ptr("server.go")},
 			expected:    []string{"Dockerfile", "server.go"},
 		},
 		{
@@ -505,7 +505,7 @@ func TestGetDependencies(t *testing.T) {
 			description: "override default build arg",
 			dockerfile:  copyServerGoBuildArgDefaultValue,
 			workspace:   ".",
-			buildArgs:   map[string]*string{"FOO": util.StringPtr("worker.go")},
+			buildArgs:   map[string]*string{"FOO": util.Ptr("worker.go")},
 			expected:    []string{"Dockerfile", "worker.go"},
 		},
 		{
@@ -555,7 +555,7 @@ func TestGetDependencies(t *testing.T) {
 			description: "build args with an environment variable",
 			dockerfile:  copyServerGoBuildArg,
 			workspace:   ".",
-			buildArgs:   map[string]*string{"FOO": util.StringPtr("{{.FILE_NAME}}")},
+			buildArgs:   map[string]*string{"FOO": util.Ptr("{{.FILE_NAME}}")},
 			env:         []string{"FILE_NAME=server.go"},
 			expected:    []string{"Dockerfile", "server.go"},
 		},
@@ -563,7 +563,7 @@ func TestGetDependencies(t *testing.T) {
 			description: "invalid go template as build arg",
 			dockerfile:  copyServerGoBuildArg,
 			workspace:   ".",
-			buildArgs:   map[string]*string{"FOO": util.StringPtr("{{")},
+			buildArgs:   map[string]*string{"FOO": util.Ptr("{{")},
 			shouldErr:   true,
 		},
 		{
diff --git a/pkg/skaffold/docker/image_test.go b/pkg/skaffold/docker/image_test.go
index 8a6e4090d..e1d931b42 100644
--- a/pkg/skaffold/docker/image_test.go
+++ b/pkg/skaffold/docker/image_test.go
@@ -132,8 +132,8 @@ func TestBuild(t *testing.T) {
 				DockerfilePath: "Dockerfile",
 				BuildArgs: map[string]*string{
 					"k1": nil,
-					"k2": util.StringPtr("value2"),
-					"k3": util.StringPtr("{{.VALUE3}}"),
+					"k2": util.Ptr("value2"),
+					"k3": util.Ptr("{{.VALUE3}}"),
 				},
 				CacheFrom:   []string{"from-1"},
 				Target:      "target",
@@ -147,8 +147,8 @@ func TestBuild(t *testing.T) {
 				Dockerfile: "Dockerfile",
 				BuildArgs: map[string]*string{
 					"k1": nil,
-					"k2": util.StringPtr("value2"),
-					"k3": util.StringPtr("value3"),
+					"k2": util.Ptr("value2"),
+					"k3": util.Ptr("value3"),
 				},
 				CacheFrom:   []string{"from-1"},
 				AuthConfigs: allAuthConfig,
@@ -184,7 +184,7 @@ func TestBuild(t *testing.T) {
 			description: "bad build arg template",
 			artifact: &latest.DockerArtifact{
 				BuildArgs: map[string]*string{
-					"key": util.StringPtr("{{INVALID"),
+					"key": util.Ptr("{{INVALID"),
 				},
 			},
 			mode:          config.RunModes.Dev,
@@ -279,9 +279,9 @@ func TestGetBuildArgs(t *testing.T) {
 			description: "build args",
 			artifact: &latest.DockerArtifact{
 				BuildArgs: map[string]*string{
-					"key1": util.StringPtr("value1"),
+					"key1": util.Ptr("value1"),
 					"key2": nil,
-					"key3": util.StringPtr("{{.FOO}}"),
+					"key3": util.Ptr("{{.FOO}}"),
 				},
 			},
 			env:  []string{"FOO=bar"},
@@ -291,7 +291,7 @@ func TestGetBuildArgs(t *testing.T) {
 			description: "invalid build arg",
 			artifact: &latest.DockerArtifact{
 				BuildArgs: map[string]*string{
-					"key": util.StringPtr("{{INVALID"),
+					"key": util.Ptr("{{INVALID"),
 				},
 			},
 			shouldErr: true,
@@ -400,7 +400,7 @@ func TestGetBuildArgs(t *testing.T) {
 			description: "all",
 			artifact: &latest.DockerArtifact{
 				BuildArgs: map[string]*string{
-					"key1": util.StringPtr("value1"),
+					"key1": util.Ptr("value1"),
 				},
 				CacheFrom:   []string{"foo"},
 				Target:      "stage1",
diff --git a/pkg/skaffold/docker/parse_test.go b/pkg/skaffold/docker/parse_test.go
index bb00d6683..26c2bf857 100644
--- a/pkg/skaffold/docker/parse_test.go
+++ b/pkg/skaffold/docker/parse_test.go
@@ -51,8 +51,8 @@ func TestRemoveExtraBuildArgs(t *testing.T) {
 			description: "no args in dockerfile",
 			dockerfile:  `FROM nginx:stable`,
 			buildArgs: map[string]*string{
-				"foo": util.StringPtr("FOO"),
-				"bar": util.StringPtr("BAR"),
+				"foo": util.Ptr("FOO"),
+				"bar": util.Ptr("BAR"),
 			},
 			expected: map[string]*string{},
 		},
@@ -62,12 +62,12 @@ func TestRemoveExtraBuildArgs(t *testing.T) {
 ARG bar
 FROM nginx:stable`,
 			buildArgs: map[string]*string{
-				"foo": util.StringPtr("FOO"),
-				"bar": util.StringPtr("BAR"),
+				"foo": util.Ptr("FOO"),
+				"bar": util.Ptr("BAR"),
 			},
 			expected: map[string]*string{
-				"foo": util.StringPtr("FOO"),
-				"bar": util.StringPtr("BAR"),
+				"foo": util.Ptr("FOO"),
+				"bar": util.Ptr("BAR"),
 			},
 		},
 		{
@@ -76,14 +76,14 @@ FROM nginx:stable`,
 ARG bar
 FROM nginx:stable`,
 			buildArgs: map[string]*string{
-				"foo":    util.StringPtr("FOO"),
-				"bar":    util.StringPtr("BAR"),
-				"foobar": util.StringPtr("FOOBAR"),
-				"gopher": util.StringPtr("GOPHER"),
+				"foo":    util.Ptr("FOO"),
+				"bar":    util.Ptr("BAR"),
+				"foobar": util.Ptr("FOOBAR"),
+				"gopher": util.Ptr("GOPHER"),
 			},
 			expected: map[string]*string{
-				"foo": util.StringPtr("FOO"),
-				"bar": util.StringPtr("BAR"),
+				"foo": util.Ptr("FOO"),
+				"bar": util.Ptr("BAR"),
 			},
 		},
 		{
@@ -94,14 +94,14 @@ ARG bar1
 FROM golang:stable
 ARG bar2`,
 			buildArgs: map[string]*string{
-				"foo":  util.StringPtr("FOO"),
-				"bar1": util.StringPtr("BAR"),
-				"bar2": util.StringPtr("BAR2"),
+				"foo":  util.Ptr("FOO"),
+				"bar1": util.Ptr("BAR"),
+				"bar2": util.Ptr("BAR2"),
 			},
 			expected: map[string]*string{
-				"foo":  util.StringPtr("FOO"),
-				"bar1": util.StringPtr("BAR"),
-				"bar2": util.StringPtr("BAR2"),
+				"foo":  util.Ptr("FOO"),
+				"bar1": util.Ptr("BAR"),
+				"bar2": util.Ptr("BAR2"),
 			},
 		},
 	}
diff --git a/pkg/skaffold/docker/syncmap_test.go b/pkg/skaffold/docker/syncmap_test.go
index 3ca9be44b..ffefea6e7 100644
--- a/pkg/skaffold/docker/syncmap_test.go
+++ b/pkg/skaffold/docker/syncmap_test.go
@@ -292,28 +292,28 @@ func TestSyncMap(t *testing.T) {
 			description: "build args",
 			dockerfile:  copyServerGoBuildArg,
 			workspace:   ".",
-			buildArgs:   map[string]*string{"FOO": util.StringPtr("server.go")},
+			buildArgs:   map[string]*string{"FOO": util.Ptr("server.go")},
 			expected:    map[string][]string{"server.go": {"/server.go"}},
 		},
 		{
 			description: "build args with same prefix",
 			dockerfile:  copyWorkerGoBuildArgSamePrefix,
 			workspace:   ".",
-			buildArgs:   map[string]*string{"FOO2": util.StringPtr("worker.go")},
+			buildArgs:   map[string]*string{"FOO2": util.Ptr("worker.go")},
 			expected:    map[string][]string{"worker.go": {"/worker.go"}},
 		},
 		{
 			description: "build args with curly braces",
 			dockerfile:  copyServerGoBuildArgCurlyBraces,
 			workspace:   ".",
-			buildArgs:   map[string]*string{"FOO": util.StringPtr("server.go")},
+			buildArgs:   map[string]*string{"FOO": util.Ptr("server.go")},
 			expected:    map[string][]string{"server.go": {"/server.go"}},
 		},
 		{
 			description: "build args with extra whitespace",
 			dockerfile:  copyServerGoBuildArgExtraWhitespace,
 			workspace:   ".",
-			buildArgs:   map[string]*string{"FOO": util.StringPtr("server.go")},
+			buildArgs:   map[string]*string{"FOO": util.Ptr("server.go")},
 			expected:    map[string][]string{"server.go": {"/server.go"}},
 		},
 		{
@@ -338,7 +338,7 @@ func TestSyncMap(t *testing.T) {
 			description: "override default build arg",
 			dockerfile:  copyServerGoBuildArgDefaultValue,
 			workspace:   ".",
-			buildArgs:   map[string]*string{"FOO": util.StringPtr("worker.go")},
+			buildArgs:   map[string]*string{"FOO": util.Ptr("worker.go")},
 			expected:    map[string][]string{"worker.go": {"/worker.go"}},
 		},
 		{
diff --git a/pkg/skaffold/git/gitutil_test.go b/pkg/skaffold/git/gitutil_test.go
index 38a05e7e8..2e362b708 100644
--- a/pkg/skaffold/git/gitutil_test.go
+++ b/pkg/skaffold/git/gitutil_test.go
@@ -141,7 +141,7 @@ func TestSyncRepo(t *testing.T) {
 		},
 		{
 			description: "existing dirty repo with sync off succeeds",
-			g:           latest.GitInfo{Repo: "http://github.com/foo.git", Path: "bar/skaffold.yaml", Ref: "master", Sync: util.BoolPtr(false)},
+			g:           latest.GitInfo{Repo: "http://github.com/foo.git", Path: "bar/skaffold.yaml", Ref: "master", Sync: util.Ptr(false)},
 			existing:    true,
 			cmds: []cmdResponse{
 				{cmd: "git remote -v", out: "origin git@github.com/foo.git"},
@@ -161,7 +161,7 @@ func TestSyncRepo(t *testing.T) {
 		},
 		{
 			description: "existing repo with uncommitted changes and sync on resets",
-			g:           latest.GitInfo{Repo: "http://github.com/foo.git", Path: "bar/skaffold.yaml", Ref: "master", Sync: util.BoolPtr(true)},
+			g:           latest.GitInfo{Repo: "http://github.com/foo.git", Path: "bar/skaffold.yaml", Ref: "master", Sync: util.Ptr(true)},
 			existing:    true,
 			cmds: []cmdResponse{
 				{cmd: "git remote -v", out: "origin git@github.com/foo.git"},
@@ -173,7 +173,7 @@ func TestSyncRepo(t *testing.T) {
 		},
 		{
 			description: "existing repo with unpushed commits and sync on resets",
-			g:           latest.GitInfo{Repo: "http://github.com/foo.git", Path: "bar/skaffold.yaml", Ref: "master", Sync: util.BoolPtr(true)},
+			g:           latest.GitInfo{Repo: "http://github.com/foo.git", Path: "bar/skaffold.yaml", Ref: "master", Sync: util.Ptr(true)},
 			existing:    true,
 			cmds: []cmdResponse{
 				{cmd: "git remote -v", out: "origin git@github.com/foo.git"},
diff --git a/pkg/skaffold/hooks/env_test.go b/pkg/skaffold/hooks/env_test.go
index 28a161faa..b3db4f9c4 100644
--- a/pkg/skaffold/hooks/env_test.go
+++ b/pkg/skaffold/hooks/env_test.go
@@ -29,11 +29,11 @@ func TestSetupStaticEnvOptions(t *testing.T) {
 	}()
 
 	cfg := mockCfg{
-		defaultRepo:    util.StringPtr("gcr.io/foo"),
-		multiLevelRepo: util.BoolPtr(true),
+		defaultRepo:    util.Ptr("gcr.io/foo"),
+		multiLevelRepo: util.Ptr(true),
 		workDir:        ".",
-		rpcPort:        util.IntPtr(8080),
-		httpPort:       util.IntPtr(8081),
+		rpcPort:        util.Ptr(8080),
+		httpPort:       util.Ptr(8081),
 	}
 	SetupStaticEnvOptions(cfg)
 	testutil.CheckDeepEqual(t, cfg.defaultRepo, staticEnvOpts.DefaultRepo)
@@ -52,10 +52,10 @@ func TestGetEnv(t *testing.T) {
 		{
 			description: "static env opts, all defined",
 			input: StaticEnvOpts{
-				DefaultRepo:    util.StringPtr("gcr.io/foo"),
-				MultiLevelRepo: util.BoolPtr(true),
-				RPCPort:        util.IntPtr(8080),
-				HTTPPort:       util.IntPtr(8081),
+				DefaultRepo:    util.Ptr("gcr.io/foo"),
+				MultiLevelRepo: util.Ptr(true),
+				RPCPort:        util.Ptr(8080),
+				HTTPPort:       util.Ptr(8081),
 				WorkDir:        "./foo",
 			},
 			expected: []string{
@@ -69,8 +69,8 @@ func TestGetEnv(t *testing.T) {
 		{
 			description: "static env opts, some missing",
 			input: StaticEnvOpts{
-				RPCPort:  util.IntPtr(8080),
-				HTTPPort: util.IntPtr(8081),
+				RPCPort:  util.Ptr(8080),
+				HTTPPort: util.Ptr(8081),
 				WorkDir:  "./foo",
 			},
 			expected: []string{
@@ -100,8 +100,8 @@ func TestGetEnv(t *testing.T) {
 			description: "sync env opts, all defined",
 			input: SyncEnvOpts{
 				Image:                "foo",
-				FilesAddedOrModified: util.StringPtr("./foo/1;./foo/2"),
-				FilesDeleted:         util.StringPtr("./foo/3;./foo/4"),
+				FilesAddedOrModified: util.Ptr("./foo/1;./foo/2"),
+				FilesDeleted:         util.Ptr("./foo/3;./foo/4"),
 				KubeContext:          "minikube",
 				Namespaces:           "np1,np2,np3",
 				BuildContext:         "./foo",
diff --git a/pkg/skaffold/inspect/buildEnv/add_local_test.go b/pkg/skaffold/inspect/buildEnv/add_local_test.go
index ae0fb8f0d..42c029739 100644
--- a/pkg/skaffold/inspect/buildEnv/add_local_test.go
+++ b/pkg/skaffold/inspect/buildEnv/add_local_test.go
@@ -46,7 +46,7 @@ func TestAddLocalBuildEnv(t *testing.T) {
 	}{
 		{
 			description:  "add to default pipeline",
-			buildEnvOpts: inspect.BuildEnvOptions{Push: util.BoolPtr(true), TryImportMissing: util.BoolPtr(false), UseDockerCLI: util.BoolPtr(false), UseBuildkit: nil, Concurrency: 2},
+			buildEnvOpts: inspect.BuildEnvOptions{Push: util.Ptr(true), TryImportMissing: util.Ptr(false), UseDockerCLI: util.Ptr(false), UseBuildkit: nil, Concurrency: 2},
 			expectedConfigs: []string{
 				`apiVersion: ""
 kind: ""
@@ -81,7 +81,7 @@ profiles:
 		{
 			description:  "add to existing profile",
 			profile:      "p1",
-			buildEnvOpts: inspect.BuildEnvOptions{Push: util.BoolPtr(true), TryImportMissing: util.BoolPtr(false), UseDockerCLI: util.BoolPtr(false), UseBuildkit: nil, Concurrency: 2},
+			buildEnvOpts: inspect.BuildEnvOptions{Push: util.Ptr(true), TryImportMissing: util.Ptr(false), UseDockerCLI: util.Ptr(false), UseBuildkit: nil, Concurrency: 2},
 			expectedConfigs: []string{
 				`apiVersion: ""
 kind: ""
@@ -128,7 +128,7 @@ profiles:
 		{
 			description:  "add to new profile",
 			profile:      "p2",
-			buildEnvOpts: inspect.BuildEnvOptions{Push: util.BoolPtr(true), TryImportMissing: util.BoolPtr(false), UseDockerCLI: util.BoolPtr(false), UseBuildkit: nil, Concurrency: 2},
+			buildEnvOpts: inspect.BuildEnvOptions{Push: util.Ptr(true), TryImportMissing: util.Ptr(false), UseDockerCLI: util.Ptr(false), UseBuildkit: nil, Concurrency: 2},
 			expectedConfigs: []string{
 				`apiVersion: ""
 kind: ""
@@ -185,7 +185,7 @@ profiles:
 			description:  "add to new profile in selected modules",
 			modules:      []string{"cfg1_1"},
 			profile:      "p2",
-			buildEnvOpts: inspect.BuildEnvOptions{Push: util.BoolPtr(true), TryImportMissing: util.BoolPtr(false), UseDockerCLI: util.BoolPtr(false), UseBuildkit: nil, Concurrency: 2},
+			buildEnvOpts: inspect.BuildEnvOptions{Push: util.Ptr(true), TryImportMissing: util.Ptr(false), UseDockerCLI: util.Ptr(false), UseBuildkit: nil, Concurrency: 2},
 			expectedConfigs: []string{
 				`apiVersion: ""
 kind: ""
@@ -237,7 +237,7 @@ profiles:
 			description:  "add to new profile in nested module",
 			modules:      []string{"cfg2"},
 			profile:      "p2",
-			buildEnvOpts: inspect.BuildEnvOptions{Push: util.BoolPtr(true), TryImportMissing: util.BoolPtr(false), UseDockerCLI: util.BoolPtr(false), UseBuildkit: nil, Concurrency: 2},
+			buildEnvOpts: inspect.BuildEnvOptions{Push: util.Ptr(true), TryImportMissing: util.Ptr(false), UseDockerCLI: util.Ptr(false), UseBuildkit: nil, Concurrency: 2},
 			expectedConfigs: []string{"",
 				`apiVersion: ""
 kind: ""
diff --git a/pkg/skaffold/instrumentation/prompt/prompt_test.go b/pkg/skaffold/instrumentation/prompt/prompt_test.go
index c44887f05..f1a02cc34 100644
--- a/pkg/skaffold/instrumentation/prompt/prompt_test.go
+++ b/pkg/skaffold/instrumentation/prompt/prompt_test.go
@@ -54,11 +54,11 @@ func TestShouldDisplayMetricsPrompt(t *testing.T) {
 		},
 		{
 			name:   "collect-metrics false",
-			config: &config.ContextConfig{CollectMetrics: util.BoolPtr(false)},
+			config: &config.ContextConfig{CollectMetrics: util.Ptr(false)},
 		},
 		{
 			name:   "collect-metrics true",
-			config: &config.ContextConfig{CollectMetrics: util.BoolPtr(true)},
+			config: &config.ContextConfig{CollectMetrics: util.Ptr(true)},
 		},
 	}
 	for _, test := range tests {
diff --git a/pkg/skaffold/parser/config_test.go b/pkg/skaffold/parser/config_test.go
index ff3e47121..768995240 100644
--- a/pkg/skaffold/parser/config_test.go
+++ b/pkg/skaffold/parser/config_test.go
@@ -456,7 +456,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute false; no dependencies",
-			makePathsAbsolute: util.BoolPtr(false),
+			makePathsAbsolute: util.Ptr(false),
 			documents:         []document{{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: ""}}}},
 			expected: func(string) []schemaUtil.VersionedConfig {
 				return []schemaUtil.VersionedConfig{
@@ -466,7 +466,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute false; no dependencies, config flag",
-			makePathsAbsolute: util.BoolPtr(false),
+			makePathsAbsolute: util.Ptr(false),
 			documents:         []document{{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: ""}, {name: "cfg01", requiresStanza: ""}}}},
 			expected: func(string) []schemaUtil.VersionedConfig {
 				return []schemaUtil.VersionedConfig{
@@ -477,7 +477,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute false; no dependencies, config flag, profiles flag",
-			makePathsAbsolute: util.BoolPtr(false),
+			makePathsAbsolute: util.Ptr(false),
 			documents:         []document{{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: ""}, {name: "cfg01", requiresStanza: ""}}}},
 			expected: func(string) []schemaUtil.VersionedConfig {
 				return []schemaUtil.VersionedConfig{
@@ -489,7 +489,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute false; branch dependencies",
-			makePathsAbsolute: util.BoolPtr(false),
+			makePathsAbsolute: util.Ptr(false),
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
 requires:
@@ -512,7 +512,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute false; cascading dependencies",
-			makePathsAbsolute: util.BoolPtr(false),
+			makePathsAbsolute: util.Ptr(false),
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
 requires:
@@ -537,7 +537,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute false; self dependency",
-			makePathsAbsolute: util.BoolPtr(false),
+			makePathsAbsolute: util.Ptr(false),
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
 requires:
@@ -558,7 +558,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute false; dependencies in same file",
-			makePathsAbsolute: util.BoolPtr(false),
+			makePathsAbsolute: util.Ptr(false),
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
 requires:
@@ -579,7 +579,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute false; looped dependencies",
-			makePathsAbsolute: util.BoolPtr(false),
+			makePathsAbsolute: util.Ptr(false),
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
 requires:
@@ -608,7 +608,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute false; dependencies with profile in root, not in dependent",
-			makePathsAbsolute: util.BoolPtr(false),
+			makePathsAbsolute: util.Ptr(false),
 			profiles:          []string{"pf0"},
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
@@ -634,7 +634,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute false; dependencies with profile in dependent activated by profile in root",
-			makePathsAbsolute: util.BoolPtr(false),
+			makePathsAbsolute: util.Ptr(false),
 			profiles:          []string{"pf0"},
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
@@ -666,7 +666,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute false; dependencies with auto-activated profile in dependent (no `activatedBy` clause)",
-			makePathsAbsolute: util.BoolPtr(false),
+			makePathsAbsolute: util.Ptr(false),
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
 requires:
@@ -695,7 +695,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute false; named profile not found",
-			makePathsAbsolute: util.BoolPtr(false),
+			makePathsAbsolute: util.Ptr(false),
 			profiles:          []string{"pf0", "pf2"},
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
@@ -720,7 +720,7 @@ requires:
 		},
 		{
 			description:       "cascading dependencies with config flag",
-			makePathsAbsolute: util.BoolPtr(false),
+			makePathsAbsolute: util.Ptr(false),
 			configFilter:      []string{"cfg11"},
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
@@ -752,7 +752,7 @@ requires:
 		},
 		{
 			description:       "named config not found",
-			makePathsAbsolute: util.BoolPtr(false),
+			makePathsAbsolute: util.Ptr(false),
 			configFilter:      []string{"cfg3"},
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
@@ -779,7 +779,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute false; duplicate config names across multiple configs",
-			makePathsAbsolute: util.BoolPtr(false),
+			makePathsAbsolute: util.Ptr(false),
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
 requires:
@@ -796,7 +796,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute false; duplicate config names in main config",
-			makePathsAbsolute: util.BoolPtr(false),
+			makePathsAbsolute: util.Ptr(false),
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00"}, {name: "cfg00"}}},
 			},
@@ -804,7 +804,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute false; remote dependencies",
-			makePathsAbsolute: util.BoolPtr(false),
+			makePathsAbsolute: util.Ptr(false),
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
 requires:
@@ -838,7 +838,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute true; no dependencies",
-			makePathsAbsolute: util.BoolPtr(true),
+			makePathsAbsolute: util.Ptr(true),
 			documents:         []document{{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: ""}}}},
 			expected: func(base string) []schemaUtil.VersionedConfig {
 				return []schemaUtil.VersionedConfig{
@@ -848,7 +848,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute true; no dependencies, config flag",
-			makePathsAbsolute: util.BoolPtr(true),
+			makePathsAbsolute: util.Ptr(true),
 			documents:         []document{{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: ""}, {name: "cfg01", requiresStanza: ""}}}},
 			expected: func(base string) []schemaUtil.VersionedConfig {
 				return []schemaUtil.VersionedConfig{
@@ -859,7 +859,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute true; no dependencies, config flag, profiles flag",
-			makePathsAbsolute: util.BoolPtr(true),
+			makePathsAbsolute: util.Ptr(true),
 			documents:         []document{{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: ""}, {name: "cfg01", requiresStanza: ""}}}},
 			expected: func(base string) []schemaUtil.VersionedConfig {
 				return []schemaUtil.VersionedConfig{
@@ -871,7 +871,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute true; branch dependencies",
-			makePathsAbsolute: util.BoolPtr(true),
+			makePathsAbsolute: util.Ptr(true),
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
 requires:
@@ -894,7 +894,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute true; cascading dependencies",
-			makePathsAbsolute: util.BoolPtr(true),
+			makePathsAbsolute: util.Ptr(true),
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
 requires:
@@ -919,7 +919,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute true; self dependency",
-			makePathsAbsolute: util.BoolPtr(true),
+			makePathsAbsolute: util.Ptr(true),
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
 requires:
@@ -940,7 +940,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute true; dependencies in same file",
-			makePathsAbsolute: util.BoolPtr(true),
+			makePathsAbsolute: util.Ptr(true),
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
 requires:
@@ -961,7 +961,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute true; looped dependencies",
-			makePathsAbsolute: util.BoolPtr(true),
+			makePathsAbsolute: util.Ptr(true),
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
 requires:
@@ -990,7 +990,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute true; dependencies with profile in root, not in dependent",
-			makePathsAbsolute: util.BoolPtr(true),
+			makePathsAbsolute: util.Ptr(true),
 			profiles:          []string{"pf0"},
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
@@ -1016,7 +1016,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute true; dependencies with profile in dependent activated by profile in root",
-			makePathsAbsolute: util.BoolPtr(true),
+			makePathsAbsolute: util.Ptr(true),
 			profiles:          []string{"pf0"},
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
@@ -1048,7 +1048,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute true; dependencies with auto-activated profile in dependent (no `activatedBy` clause)",
-			makePathsAbsolute: util.BoolPtr(true),
+			makePathsAbsolute: util.Ptr(true),
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
 requires:
@@ -1077,7 +1077,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute true; named profile not found",
-			makePathsAbsolute: util.BoolPtr(true),
+			makePathsAbsolute: util.Ptr(true),
 			profiles:          []string{"pf0", "pf2"},
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
@@ -1102,7 +1102,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute true; cascading dependencies with config flag",
-			makePathsAbsolute: util.BoolPtr(true),
+			makePathsAbsolute: util.Ptr(true),
 			configFilter:      []string{"cfg11"},
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
@@ -1134,7 +1134,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute true; named config not found",
-			makePathsAbsolute: util.BoolPtr(true),
+			makePathsAbsolute: util.Ptr(true),
 			configFilter:      []string{"cfg3"},
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
@@ -1161,7 +1161,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute true; duplicate config names across multiple configs",
-			makePathsAbsolute: util.BoolPtr(true),
+			makePathsAbsolute: util.Ptr(true),
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
 requires:
@@ -1178,7 +1178,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute true; duplicate config names in main config",
-			makePathsAbsolute: util.BoolPtr(true),
+			makePathsAbsolute: util.Ptr(true),
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00"}, {name: "cfg00"}}},
 			},
@@ -1186,7 +1186,7 @@ requires:
 		},
 		{
 			description:       "makePathsAbsolute true; remote dependencies",
-			makePathsAbsolute: util.BoolPtr(true),
+			makePathsAbsolute: util.Ptr(true),
 			documents: []document{
 				{path: "skaffold.yaml", configs: []mockCfg{{name: "cfg00", requiresStanza: `
 requires:
@@ -1246,7 +1246,7 @@ requires:
 		},
 		{
 			description:              "makePathsAbsolute false; recursively applied profiles",
-			makePathsAbsolute:        util.BoolPtr(false),
+			makePathsAbsolute:        util.Ptr(false),
 			profiles:                 []string{"pf0"},
 			applyProfilesRecursively: true,
 			documents: []document{
@@ -1273,7 +1273,7 @@ requires:
 		},
 		{
 			description:              "makePathsAbsolute true; recursively applied profiles",
-			makePathsAbsolute:        util.BoolPtr(true),
+			makePathsAbsolute:        util.Ptr(true),
 			profiles:                 []string{"pf0"},
 			applyProfilesRecursively: true,
 			documents: []document{
diff --git a/pkg/skaffold/schema/defaults/defaults_test.go b/pkg/skaffold/schema/defaults/defaults_test.go
index 607a8ae01..fc05645aa 100644
--- a/pkg/skaffold/schema/defaults/defaults_test.go
+++ b/pkg/skaffold/schema/defaults/defaults_test.go
@@ -81,7 +81,7 @@ func TestSetDefaults(t *testing.T) {
 						ArtifactType: latest.ArtifactType{
 							BuildpackArtifact: &latest.BuildpackArtifact{},
 						},
-						Sync: &latest.Sync{Auto: util.BoolPtr(false)},
+						Sync: &latest.Sync{Auto: util.Ptr(false)},
 					},
 				},
 			},
@@ -110,22 +110,22 @@ func TestSetDefaults(t *testing.T) {
 	testutil.CheckDeepEqual(t, []string{"."}, cfg.Build.Artifacts[3].BuildpackArtifact.Dependencies.Paths)
 	testutil.CheckDeepEqual(t, []string(nil), cfg.Build.Artifacts[3].BuildpackArtifact.Dependencies.Ignore)
 	testutil.CheckDeepEqual(t, "project.toml", cfg.Build.Artifacts[3].BuildpackArtifact.ProjectDescriptor)
-	testutil.CheckDeepEqual(t, util.BoolPtr(true), cfg.Build.Artifacts[3].Sync.Auto)
+	testutil.CheckDeepEqual(t, util.Ptr(true), cfg.Build.Artifacts[3].Sync.Auto)
 
 	testutil.CheckDeepEqual(t, "fifth", cfg.Build.Artifacts[4].ImageName)
-	testutil.CheckDeepEqual(t, util.BoolPtr(true), cfg.Build.Artifacts[4].Sync.Auto)
+	testutil.CheckDeepEqual(t, util.Ptr(true), cfg.Build.Artifacts[4].Sync.Auto)
 
 	testutil.CheckDeepEqual(t, "sixth", cfg.Build.Artifacts[5].ImageName)
 	testutil.CheckDeepEqual(t, []string{"."}, cfg.Build.Artifacts[5].BuildpackArtifact.Dependencies.Paths)
 	testutil.CheckDeepEqual(t, []string(nil), cfg.Build.Artifacts[5].BuildpackArtifact.Dependencies.Ignore)
 	testutil.CheckDeepEqual(t, "project.toml", cfg.Build.Artifacts[5].BuildpackArtifact.ProjectDescriptor)
-	testutil.CheckDeepEqual(t, util.BoolPtr(true), cfg.Build.Artifacts[5].Sync.Auto)
+	testutil.CheckDeepEqual(t, util.Ptr(true), cfg.Build.Artifacts[5].Sync.Auto)
 
 	testutil.CheckDeepEqual(t, "seventh", cfg.Build.Artifacts[6].ImageName)
 	testutil.CheckDeepEqual(t, []string{"."}, cfg.Build.Artifacts[6].BuildpackArtifact.Dependencies.Paths)
 	testutil.CheckDeepEqual(t, []string(nil), cfg.Build.Artifacts[6].BuildpackArtifact.Dependencies.Ignore)
 	testutil.CheckDeepEqual(t, "project.toml", cfg.Build.Artifacts[6].BuildpackArtifact.ProjectDescriptor)
-	testutil.CheckDeepEqual(t, util.BoolPtr(false), cfg.Build.Artifacts[6].Sync.Auto)
+	testutil.CheckDeepEqual(t, util.Ptr(false), cfg.Build.Artifacts[6].Sync.Auto)
 }
 
 func TestSetDefaultsOnCluster(t *testing.T) {
diff --git a/pkg/skaffold/survey/survey_test.go b/pkg/skaffold/survey/survey_test.go
index 81b8937e2..e4eae7c37 100644
--- a/pkg/skaffold/survey/survey_test.go
+++ b/pkg/skaffold/survey/survey_test.go
@@ -82,7 +82,7 @@ func TestShouldDisplayPrompt(t *testing.T) {
 			description: "should not display prompt when prompt is disabled",
 			cfg: &sConfig.GlobalConfig{
 				Global: &sConfig.ContextConfig{
-					Survey: &sConfig.SurveyConfig{DisablePrompt: util.BoolPtr(true)},
+					Survey: &sConfig.SurveyConfig{DisablePrompt: util.Ptr(true)},
 				}},
 		},
 		{
@@ -90,7 +90,7 @@ func TestShouldDisplayPrompt(t *testing.T) {
 			cfg: &sConfig.GlobalConfig{
 				Global: &sConfig.ContextConfig{
 					Survey: &sConfig.SurveyConfig{
-						DisablePrompt: util.BoolPtr(false),
+						DisablePrompt: util.Ptr(false),
 						LastPrompted:  threeDaysAgo,
 					}},
 			},
@@ -100,7 +100,7 @@ func TestShouldDisplayPrompt(t *testing.T) {
 			cfg: &sConfig.GlobalConfig{
 				Global: &sConfig.ContextConfig{
 					Survey: &sConfig.SurveyConfig{
-						DisablePrompt: util.BoolPtr(false),
+						DisablePrompt: util.Ptr(false),
 						LastTaken:     twoMonthsAgo,
 					}},
 			},
@@ -110,7 +110,7 @@ func TestShouldDisplayPrompt(t *testing.T) {
 			cfg: &sConfig.GlobalConfig{
 				Global: &sConfig.ContextConfig{
 					Survey: &sConfig.SurveyConfig{
-						DisablePrompt: util.BoolPtr(false),
+						DisablePrompt: util.Ptr(false),
 						LastPrompted:  fiveDaysAgo,
 					}},
 			},
@@ -121,7 +121,7 @@ func TestShouldDisplayPrompt(t *testing.T) {
 			cfg: &sConfig.GlobalConfig{
 				Global: &sConfig.ContextConfig{
 					Survey: &sConfig.SurveyConfig{
-						DisablePrompt: util.BoolPtr(false),
+						DisablePrompt: util.Ptr(false),
 						LastTaken:     threeMonthsAgo,
 					}},
 			},
@@ -132,7 +132,7 @@ func TestShouldDisplayPrompt(t *testing.T) {
 			cfg: &sConfig.GlobalConfig{
 				Global: &sConfig.ContextConfig{
 					Survey: &sConfig.SurveyConfig{
-						DisablePrompt: util.BoolPtr(false),
+						DisablePrompt: util.Ptr(false),
 						LastTaken:     twoMonthsAgo,
 						LastPrompted:  twoMonthsAgo,
 					}},
@@ -166,14 +166,14 @@ func TestIsSurveyPromptDisabled(t *testing.T) {
 		{
 			description: "config disable-prompt is true",
 			cfg: &sConfig.GlobalConfig{
-				Global: &sConfig.ContextConfig{Survey: &sConfig.SurveyConfig{DisablePrompt: util.BoolPtr(true)}},
+				Global: &sConfig.ContextConfig{Survey: &sConfig.SurveyConfig{DisablePrompt: util.Ptr(true)}},
 			},
 			expected: true,
 		},
 		{
 			description: "config disable-prompt is false",
 			cfg: &sConfig.GlobalConfig{
-				Global: &sConfig.ContextConfig{Survey: &sConfig.SurveyConfig{DisablePrompt: util.BoolPtr(false)}},
+				Global: &sConfig.ContextConfig{Survey: &sConfig.SurveyConfig{DisablePrompt: util.Ptr(false)}},
 			},
 		},
 		{
@@ -259,7 +259,7 @@ func TestRecentlyPromptedOrTaken(t *testing.T) {
 			cfg: &sConfig.GlobalConfig{
 				Global: &sConfig.ContextConfig{Survey: &sConfig.SurveyConfig{LastTaken: twoMonthsAgo,
 					UserSurveys: []*sConfig.UserSurvey{
-						{ID: "user", Taken: util.BoolPtr(true)},
+						{ID: "user", Taken: util.Ptr(true)},
 					}}}},
 			input: []config{hats, {id: "user", expiresAt: future,
 				isRelevantFn: func(_ []schemaUtil.VersionedConfig, _ sConfig.RunMode) bool {
@@ -273,7 +273,7 @@ func TestRecentlyPromptedOrTaken(t *testing.T) {
 			cfg: &sConfig.GlobalConfig{
 				Global: &sConfig.ContextConfig{Survey: &sConfig.SurveyConfig{
 					UserSurveys: []*sConfig.UserSurvey{
-						{ID: "user", Taken: util.BoolPtr(true)},
+						{ID: "user", Taken: util.Ptr(true)},
 					}}}},
 			input: []config{hats, {id: "user", expiresAt: future,
 				isRelevantFn: func(_ []schemaUtil.VersionedConfig, _ sConfig.RunMode) bool {
diff --git a/pkg/skaffold/sync/sync_test.go b/pkg/skaffold/sync/sync_test.go
index 5472559dd..56a1be665 100644
--- a/pkg/skaffold/sync/sync_test.go
+++ b/pkg/skaffold/sync/sync_test.go
@@ -651,7 +651,7 @@ func TestNewSyncItem(t *testing.T) {
 				},
 				ImageName: "test",
 				Sync: &latest.Sync{
-					Auto: util.BoolPtr(true),
+					Auto: util.Ptr(true),
 				},
 				Workspace: ".",
 			},
@@ -691,7 +691,7 @@ func TestNewSyncItem(t *testing.T) {
 				},
 				ImageName: "test",
 				Sync: &latest.Sync{
-					Auto: util.BoolPtr(true),
+					Auto: util.Ptr(true),
 				},
 				Workspace: ".",
 			},
@@ -725,7 +725,7 @@ func TestNewSyncItem(t *testing.T) {
 				ImageName: "test",
 				Workspace: ".",
 				Sync: &latest.Sync{
-					Auto: util.BoolPtr(true),
+					Auto: util.Ptr(true),
 				},
 				ArtifactType: latest.ArtifactType{
 					JibArtifact: &latest.JibArtifact{},
@@ -1108,18 +1108,18 @@ func TestInit(t *testing.T) {
 		},
 		{
 			description: "sync on, auto on, non-jib",
-			artifact:    &latest.Artifact{Sync: &latest.Sync{Auto: util.BoolPtr(true)}},
+			artifact:    &latest.Artifact{Sync: &latest.Sync{Auto: util.Ptr(true)}},
 			shouldInit:  false,
 		},
 		{
 			description: "sync on, auto on, jib",
-			artifact:    &latest.Artifact{ArtifactType: latest.ArtifactType{JibArtifact: &latest.JibArtifact{}}, Sync: &latest.Sync{Auto: util.BoolPtr(true)}},
+			artifact:    &latest.Artifact{ArtifactType: latest.ArtifactType{JibArtifact: &latest.JibArtifact{}}, Sync: &latest.Sync{Auto: util.Ptr(true)}},
 			shouldInit:  true,
 			initErrors:  false,
 		},
 		{
 			description: "sync on, auto on, jib, init fails",
-			artifact:    &latest.Artifact{ArtifactType: latest.ArtifactType{JibArtifact: &latest.JibArtifact{}}, Sync: &latest.Sync{Auto: util.BoolPtr(true)}},
+			artifact:    &latest.Artifact{ArtifactType: latest.ArtifactType{JibArtifact: &latest.JibArtifact{}}, Sync: &latest.Sync{Auto: util.Ptr(true)}},
 			shouldInit:  true,
 			initErrors:  true,
 		},
diff --git a/pkg/skaffold/util/util_test.go b/pkg/skaffold/util/util_test.go
index 4ecd1f173..5f0cf7ee7 100644
--- a/pkg/skaffold/util/util_test.go
+++ b/pkg/skaffold/util/util_test.go
@@ -322,15 +322,15 @@ func TestMapPtrToSlice(t *testing.T) {
 		{
 			description: "regular key:value",
 			args: map[string]*string{
-				"one": stringPointer("1"),
-				"two": stringPointer("2"),
+				"one": Ptr("1"),
+				"two": Ptr("2"),
 			},
 			expected: []string{"one=1", "two=2"},
 		}, {
 			description: "empty key:value",
 			args: map[string]*string{
-				"one": stringPointer(""),
-				"two": stringPointer(""),
+				"one": Ptr(""),
+				"two": Ptr(""),
 			},
 			expected: []string{"one=", "two="},
 		}, {
@@ -446,10 +446,6 @@ func TestIsURL(t *testing.T) {
 	testutil.CheckDeepEqual(t, true, IsURL("https://bar"))
 }
 
-func stringPointer(s string) *string {
-	return &s
-}
-
 func TestIsEmptyDir(t *testing.T) {
 	tmpDir := testutil.NewTempDir(t).Touch("file")
 	emptyTmpDir := testutil.NewTempDir(t)