microsoft / vscode

Visual Studio Code
https://code.visualstudio.com
MIT License
164.3k stars 29.31k forks source link

Integrated terminal opens to / instead of workspace directory #68794

Closed jorng closed 5 years ago

jorng commented 5 years ago

Issue Type: Bug

The integrated terminal is always opening to the root of my drive, instead of the workspace directory.

Oddly, there still seems to be some link to the correct directory, because git still works, but if I try to access anything in the current directory, it doesn't work (I have to cd to the project directory manually)

VS Code version: Code 1.31.1 (1b8e8302e405050205e69b59abb3559592bb9e60, 2019-02-12T02:16:38.656Z) OS version: Darwin x64 18.5.0

System Info |Item|Value| |---|---| |CPUs|Intel(R) Core(TM) i5-8259U CPU @ 2.30GHz (8 x 2300)| |GPU Status|2d_canvas: enabled
checker_imaging: disabled_off
flash_3d: enabled
flash_stage3d: enabled
flash_stage3d_baseline: enabled
gpu_compositing: enabled
multiple_raster_threads: enabled_on
native_gpu_memory_buffers: enabled
rasterization: enabled
surface_synchronization: enabled_on
video_decode: enabled
webgl: enabled
webgl2: enabled| |Load (avg)|2, 3, 3| |Memory (System)|16.00GB (1.33GB free)| |Process Argv|| |Screen Reader|no| |VM|0%|
Extensions (35) Extension|Author (truncated)|Version ---|---|--- vscode-direnv|Rub|0.0.2 fish|Ted|0.0.4 project-manager|ale|10.3.2 unique-lines|bib|1.0.0 better-toml|bun|0.3.2 solargraph|cas|0.19.3 handlebars-preview|cha|1.1.0 gitignore|cod|0.6.0 vscode-great-icons|emm|2.1.46 gc-excelviewer|Gra|2.1.29 jsonnet|hep|0.1.0 graphql-for-vscode|kum|1.13.0 contextualduplicate|laf|0.2.0 vs-color-picker|lih|1.0.0 rainbow-csv|mec|1.0.0 dotenv|mik|1.0.1 ruby-rubocop|mis|0.7.1 prettify-json|moh|0.0.3 python|ms-|2019.1.0 Go|ms-|0.9.2 svg-font-previewer|nko|1.1.3 vscode-docker|Pet|0.5.2 pcl-vscode|pie|0.7.0 vscode-yaml|red|0.2.1 vscode-sort-json|ric|1.13.0 python-template-snippets|Ric|1.0.0 datetime|rid|1.0.5 vscode-plush|rub|0.1.3 jinjahtml|sam|0.8.0 fish-vscode|sky|0.2.1 todo-show|suy|0.2.1 vscode-lua|tri|0.12.4 vscode-todo-highlight|way|1.0.4 change-case|wma|1.0.0 markdown-all-in-one|yzh|2.0.1 (1 theme extensions excluded)
jorng commented 5 years ago

This may be specific to fish. If I change the shell to zsh, it seems to be OK.

Strum355 commented 5 years ago

Can repro with fish. Works with bash. Only difference is, it opens my homedir rather than /

jorng commented 5 years ago

Of note, there was a new release on Feb 11, 2019. I'm pretty sure this started after I installed that update.

jorng commented 5 years ago

Confirmed, this doesn't occur with fish, version 3.0.0, only 3.0.1.

This isn't an issue when I use the Terminal app (macOS), even dragging a folder to open it directly. Anybody know how the shell is being invoked?

We should probably report this as an issue on fish-shell/fish-shell, but I don't know how to reproduce outside of VSCode.

jorng commented 5 years ago

Actually, this may be related to: fish-shell/fish-shell#5647

jorng commented 5 years ago

Duplicate of #68488