Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docker-env: Add semicolons back for fish, required for fish 2.x users #6915

Merged
merged 1 commit into from
Mar 6, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions cmd/minikube/cmd/docker-env_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -89,18 +89,18 @@ export MINIKUBE_ACTIVE_DOCKERD="ipv6"
"fish",
DockerEnvConfig{profile: "fish", driver: "kvm2", hostIP: "127.0.0.1", port: 2376, certsDir: "/certs"},
nil,
`set -gx DOCKER_TLS_VERIFY "1"
set -gx DOCKER_HOST "tcp://127.0.0.1:2376"
set -gx DOCKER_CERT_PATH "/certs"
set -gx MINIKUBE_ACTIVE_DOCKERD "fish"
`set -gx DOCKER_TLS_VERIFY "1";
set -gx DOCKER_HOST "tcp://127.0.0.1:2376";
set -gx DOCKER_CERT_PATH "/certs";
set -gx MINIKUBE_ACTIVE_DOCKERD "fish";

# To point your shell to minikube's docker-daemon, run:
# minikube -p fish docker-env | source
`,
`set -e DOCKER_TLS_VERIFY
set -e DOCKER_HOST
set -e DOCKER_CERT_PATH
set -e MINIKUBE_ACTIVE_DOCKERD
`set -e DOCKER_TLS_VERIFY;
set -e DOCKER_HOST;
set -e DOCKER_CERT_PATH;
set -e MINIKUBE_ACTIVE_DOCKERD;
`,
},
{
Expand Down
4 changes: 2 additions & 2 deletions pkg/minikube/shell/shell.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,11 @@ import (

const (
fishSetPfx = "set -gx "
fishSetSfx = "\"\n"
fishSetSfx = "\";\n" // semi-colon required for fish 2.7
fishSetDelim = " \""

fishUnsetPfx = "set -e "
fishUnsetSfx = "\n"
fishUnsetSfx = ";\n"

psSetPfx = "$Env:"
psSetSfx = "\"\n"
Expand Down