Skip to content

Cannot cd out of directory using tilda for home (~) #3143

@MozarellaMan

Description

@MozarellaMan

Describe the bug
When I try to cd out of my directory to a directory from HOME using the tilda (~) symbol, for example cd ~\Documents\ , I get the error error: Cannot change to directory. To get around it I do cd ~ then cd Documents\ but this is quite annoying. Also when I do this starship starts displaying weird (not properly showing the current dir) but that might be something to do with starship.

To Reproduce
Steps to reproduce the behavior:

  1. cd to a directory
  2. Change our of that directory with tilda like cd ~\Documents\
  3. returns "error: Cannot change to directory"

Expected behavior
To change directory to ~\Documents\

Screenshots
image

Configuration (please complete the following information):

Run version | pivot and paste the output to show OS, features, etc.

> version | pivot
╭───┬────────────────────┬───────────────────────────────────────────────────────────────────────╮
│ # │ Column0            │ Column1                                                               │
├───┼────────────────────┼───────────────────────────────────────────────────────────────────────┤
│ 0 │ version            │ 0.27.1                                                                │
│ 1 │ build_os           │ windows-x86_64                                                          │
│ 2 │ rust_version       │ rustc 1.50.0                                                          │
│ 3 │ cargo_version      │ cargo 1.50.0                                                          │
│ 4 │ pkg_version        │ 0.27.1                                                                │
│ 5 │ build_time         │ 2021-03-07 22:01:06                                                   │
│ 6 │ build_rust_channel │ release                                                               │
│ 7 │ features           │ ctrlc, default, directories, dirs, git, ichwh, ptree, │
│   │                    │ rustyline, term, uuid, which, zip                                     │
╰───┴────────────────────┴───────────────────────────────────────────────────────────────────────╯

Add any other context about the problem here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions