Bug #15550

Windows - gem bin files - can't run from bash shell

Added by MSP-Greg (Greg L) about 2 years ago. Updated almost 2 years ago.

Target version:
ruby -v:
ruby 2.7.0dev (2019-01-19 trunk 66872) [x64-mingw32]


As I recall, ruby-loco is no longer touching the gem related files located in the bin folder. Previously, there were two files associated with each gem, one with a .cmd/.bat extension, one without.

Currently, there is just one file with a .cmd extension. I have seen this before, and just came across it again, where gems are using *nix scripts run with either the MSYS2 shell or the Git shell in their CI. Hence, there is an expectation for the plain (extensionless) file to exist.

Not sure if this is considered a breaking change or a bug/issue.

Thanks, Greg

Updated by MSP-Greg (Greg L) about 2 years ago

An easy way to repo this is to open the Git bash shell, and run bundle version. I got an error message of:

bash: /c/Greg/Ruby99-x64/bin/bundle: No such file or directory

I believe the MSYS2 shell changes PATH, the Git Bash shell does not. Or, ruby -v works in Git, but not MSYS2...


Updated by MSP-Greg (Greg L) almost 2 years ago

  • Subject changed from RubyGems bin files - from two to one... to Windows - gem bin files - can't run from bash shell

Updated by hsbt (Hiroshi SHIBATA) almost 2 years ago

  • Assignee set to hsbt (Hiroshi SHIBATA)
  • Status changed from Open to Assigned

Also available in: Atom PDF