Shopify / Shopify/ruby-lsp

Linkify Ruby code references in terminal output

Open
#3,951 1 comment 0 reactions 1 assignee View on GitHub

@alexcrocha is already working on this.

Since Mar 30, 2026.

enhancement pinned
Dominant language
Ruby
Stars
2k
Forks
281
Avg merge
2h 14m
Merged PRs (30d)
6

Description

I have checked that this feature is not already implemented
  • This feature does not exist
Use case

There are several common forms of references to Ruby code that might show up in the terminal, like:

# Default `Kernel#inspect` format
#<A::B::C:0x0000000123009050 @a=1>

/Users/alex/project/example.rb:12:in 'Baz#c': unhandled exception: NotImplementedError (NotImplementedError)
	from /Users/alex/project/example.rb:8:in 'Bar#b'
	from /Users/alex/project/example.rb:4:in 'Foo#a'
	from /Users/alex/project/example.rb:15:in '<main>'

The file paths and line numbers are clickable, but not any of the Ruby code references.

Description

It would be great if RubyLSP would identify that A::B::C as a constant reference, Baz#c is a method in Baz, NotImplementedError is a class, etc., and let you go-to-def by command-clicking on these.

Implementation

It looks like TerminalLinkProvider API does exactly this.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.