.env.go.local

// Load the file. // Note: If the file doesn't exist, godotenv.Load returns an error. // We usually want to ignore this error in Production environments. if _, err := os.Stat(envPath); err == nil if err := godotenv.Load(envPath); err != nil log.Printf("Error loading .env.go.local file: %v", err) else log.Println("Loaded environment from .env.go.local")

Then in your main.go :