Skip to content

Allow vernier gem to be used optionally, but don't require it#1172

Merged
castwide merged 4 commits intocastwide:v0.59from
apiology:optional_vernier
Mar 8, 2026
Merged

Allow vernier gem to be used optionally, but don't require it#1172
castwide merged 4 commits intocastwide:v0.59from
apiology:optional_vernier

Conversation

@apiology
Copy link
Copy Markdown
Contributor

@apiology apiology commented Mar 2, 2026

Ensures solargraph can still be used on the Microsoft Windows platform

@apiology apiology marked this pull request as draft March 2, 2026 02:07
@apiology apiology marked this pull request as ready for review March 2, 2026 03:05
Comment thread lib/solargraph/shell.rb Outdated
require 'vernier'
rescue LoadError
warn 'vernier gem not found. Install with: gem install vernier'
$stderr.puts 'vernier gem not found. Add this line to your .Gemfile and run `bundle install` to use this command:'
Copy link
Copy Markdown
Owner

@castwide castwide Mar 8, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since .Gemfile is nonstandard, this notification might be confusing to users who attempt to profile Solargraph in a different project where it doesn't exist. They'd need to have both solargraph and vermier in their Gemfile. If they're not using bundler, they should only need to have vermier installed at the system level.

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Another option that was previously discussed, we could hide the command.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I wasn't thinking about using this on anything but solargraph :)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rephrased a little more generically - folks who want to profile can figure this out :)

@castwide castwide mentioned this pull request Mar 8, 2026
Comment thread lib/solargraph/shell.rb Outdated
@apiology apiology requested a review from castwide March 8, 2026 15:09
@castwide
Copy link
Copy Markdown
Owner

castwide commented Mar 8, 2026

LGTM. Confirmed installable on Windows. Thanks for collaborating on this, @lekemula and @apiology!

@castwide castwide merged commit 550483d into castwide:v0.59 Mar 8, 2026
21 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants