diff --git a/cmd/flux/main.go b/cmd/flux/main.go
index 9c49b3c54686506738efc0cd247a0eb5a6c89778..010ca7adac8c85be0872fd59e8ccd13f1910c590 100644
--- a/cmd/flux/main.go
+++ b/cmd/flux/main.go
@@ -182,13 +182,6 @@ func configureDefaultNamespace() {
 	}
 }
 
-func homeDir() string {
-	if h := os.Getenv("HOME"); h != "" {
-		return h
-	}
-	return os.Getenv("USERPROFILE") // windows
-}
-
 // readPasswordFromStdin reads a password from stdin and returns the input
 // with trailing newline and/or carriage return removed. It also makes sure that terminal
 // echoing is turned off if stdin is a terminal.