Skip to main content
quoted 'cd "$OLDPWD"' since causes the error: bash: cd: too many arguments in paths with spaces.
Source Link
αғsнιη
  • 41.9k
  • 17
  • 75
  • 118

You can use

cd - 

or you could use

cd "$OLDPWD" 

cd $OLDPWD causes the error: bash: cd: too many arguments in paths with spaces.

You can use

cd - 

or you could use

cd "$OLDPWD" 

cd $OLDPWD causes the error: bash: cd: too many arguments in paths with spaces.

You can use

cd - 

or you could use

cd "$OLDPWD" 

You can use

cd - 

or you could use

cd $OLDPWD"$OLDPWD" 

cd $OLDPWD causes the error: bash: cd: too many arguments in paths with spaces.

You can use

cd - 

or you could use

cd $OLDPWD 

You can use

cd - 

or you could use

cd "$OLDPWD" 

cd $OLDPWD causes the error: bash: cd: too many arguments in paths with spaces.

Source Link
Raphael Ahrens
  • 9.9k
  • 5
  • 39
  • 53

You can use

cd - 

or you could use

cd $OLDPWD