diff --git a/profile.d/toolbox.sh b/profile.d/toolbox.sh index 020d6e8ad..62939df4e 100644 --- a/profile.d/toolbox.sh +++ b/profile.d/toolbox.sh @@ -4,7 +4,14 @@ [ "${BASH_VERSION:-}" != "" ] || [ "${ZSH_VERSION:-}" != "" ] || return 0 [ "$PS1" != "" ] || return 0 -toolbox_config="${XDG_CONFIG_HOME:-$HOME/.config}/toolbox" +root_config="${XDG_CONFIG_HOME:-$HOME/.config}" +toolbox_config="$root_config/toolbx" +toolbox_config_old="$root_config/toolbox" + +if [ -d "$toolbox_config_old" ] && ! [ -e "$toolbox_config" ]; then + mv "$toolbox_config_old" "$toolbox_config" 2>/dev/null +fi + host_welcome_stub="$toolbox_config/host-welcome-shown" toolbox_welcome_stub="$toolbox_config/toolbox-welcome-shown" diff --git a/src/cmd/root.go b/src/cmd/root.go index 2259d3f65..713ea013a 100644 --- a/src/cmd/root.go +++ b/src/cmd/root.go @@ -238,7 +238,7 @@ func migrate(cmd *cobra.Command, args []string) error { return errors.New("failed to get the user config directory") } - toolboxConfigDir := configDir + "/toolbox" + toolboxConfigDir := configDir + "/toolbx" stampPath := toolboxConfigDir + "/podman-system-migrate" logrus.Debugf("Toolbx config directory is %s", toolboxConfigDir) diff --git a/test/system/libs/helpers.bash b/test/system/libs/helpers.bash index 4b48c7009..7d0ca2586 100644 --- a/test/system/libs/helpers.bash +++ b/test/system/libs/helpers.bash @@ -166,9 +166,9 @@ function _setup_docker_registry() { assert_success # Add certificate to Podman's trusted certificates (rootless) - run mkdir -p "$HOME"/.config/containers/certs.d/"${DOCKER_REG_URI}" + run mkdir -p "$XDG_CONFIG_HOME"/containers/certs.d/"${DOCKER_REG_URI}" assert_success - run cp "${DOCKER_REG_CERTS_DIR}"/domain.crt "$HOME"/.config/containers/certs.d/"${DOCKER_REG_URI}"/domain.crt + run cp "${DOCKER_REG_CERTS_DIR}"/domain.crt "$XDG_CONFIG_HOME"/containers/certs.d/"${DOCKER_REG_URI}"/domain.crt assert_success # Create a registry user @@ -234,7 +234,7 @@ function _clean_docker_registry() { # Remove Docker registry dir rm --force --recursive "${DOCKER_REG_ROOT}" # Remove dir with created registry certificates - rm --force --recursive "$HOME"/.config/containers/certs.d/"${DOCKER_REG_URI}" + rm --force --recursive "$XDG_CONFIG_HOME"/containers/certs.d/"${DOCKER_REG_URI}" }