Skip to content

Setup on Windows machines picks wrong terminal #1776

Closed
@MrMcDaddy

Description

@MrMcDaddy

Operating System

Windows 11

Ruby version

3.2.2

Project has a bundle

  • Has bundle

Ruby version manager being used

no manager

Description

The flow of things on a windows machine is pretty much as follows:

  1. Install Ruby-LSP extension
  2. See error message popping up that says "command 'ruby' unknown"
  3. Configure "SHELL" system environment variable to point to default "Git for Windows" directory
  4. Retry, get greeted by a message that "C:\Program" is not a command
  5. Reinstall Git for Windows straight on C:
  6. Retry and get greeted by this monstrosity:
    C:\Git\bin\bash.exe -ic 'ruby -rjson -e "STDERR.printf(%{RUBY_ENV_ACTIVATE%sRUBY_ENV_ACTIVATE}, JSON.dump({ env: ENV.to_h, ruby_version: RUBY_VERSION, yjit: defined?(RubyVM::YJIT) }))"' bash: cannot set terminal process group (-1): Inappropriate ioctl for device bash: no job control in this shell

The reason I'm not using any version manager is that whatever I'm trying to use, VS-Code tries to run the background task in CMD, which isn't really configured to be used for anything, so it fails to find the version managers or ruby itself.
The flow appears to be "CMD -> Bash -> Ruby".

I tried to change all VS Code Settings related to this, but had no luck whatsoever.

"terminal.external.windowsExec": "Git Bash",
"terminal.integrated.automationProfile.windows": {
    "path": "C:\\Git\\bin\\bash.exe"
},

I'm using Git Bash as my default terminal everywhere else on my computer, even as the default terminal within VS Code.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingpinnedThis issue or pull request is pinned and won't be marked as stale

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions