Skip to content

Approximate/fuzzy ruby versions may mismatch #19

Open
@lazyatom

Description

@lazyatom

The original chruby command allows specifying "fuzzy" ruby versions without the patch number, e.g. 2.4 which will load the highest matching available version from the 2.4 series.

Unfortunately, chruby.el does not understand this, and can actually mismatch if there's another version of ruby available which contains the "fuzzy" substring. Concretely, if you have 2.2.4 and 2.4.1 installed, calling chruby-use-corresponding when .ruby-version contains 2.4 will activate 2.2.4, not 2.4.1.

I'm a totally elisp newbie, but I think the fix will be on this line:

(and (string-match name ruby) ruby))

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions