Skip to content

Overriden cd fails to switch to paths with spaces #457

@paulourio

Description

@paulourio

When attempting to use the cd command in bash, which runs $HOME/.gvm/scripts/env/cd, to navigate to a directory with spaces in its name, the operation fails with the error message "bash: cd: too many arguments." The expected behavior is a successful navigation to directories with spaces in their names.

How to reproduce:

  1. With initialized GVM, create a directory with spaces in its name:
mkdir -p '~/foo bar'
cd '~/foo bar'
  1. The following error is encountered:
bash: cd: too many arguments

Environment:

  • Operating System: GNU/Linux
  • GVM Version: 1.0.22
  • Bash Version: 5.1.16(1)-release

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions