Skip to content
This repository has been archived by the owner on Aug 31, 2023. It is now read-only.

feat(vscode): display the version of the language server in the status bar #3616

Merged
merged 1 commit into from Nov 9, 2022

Conversation

leops
Copy link
Contributor

@leops leops commented Nov 9, 2022

Summary

Fixes #3609

This is a small addition to the VSCode extension to display the version string advertised by the language server instance (which should be the version of rome_service the server binary was built with) in the status bar item of the extension. I also took the opportunity to clean up the source code for the extension by removing extraneous files and imports, fixing a small bug in the onDidChangeActiveTextEditor handler and updating the package-lock.json file

Test Plan

I've built and run the extension locally, since I'm also using a local build of the language server the version string isn't really useful but it works:

status_version

@leops leops requested a review from a team November 9, 2022 09:32
@netlify
Copy link

netlify bot commented Nov 9, 2022

Deploy Preview for docs-rometools canceled.

Name Link
🔨 Latest commit 03204d7
🔍 Latest deploy log https://app.netlify.com/sites/docs-rometools/deploys/636b73b571f17200097e9ca5

Copy link
Contributor

@MichaReiser MichaReiser left a comment

Choose a reason for hiding this comment

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

fixing a small bug in the onDidChangeActiveTextEditor handler and updating the package-lock.json file

What was the bug?

@leops
Copy link
Contributor Author

leops commented Nov 9, 2022

fixing a small bug in the onDidChangeActiveTextEditor handler and updating the package-lock.json file

What was the bug?

The event handler was missing a return if the textEditor argument is undefined, so this branch was falling through and tried to destructure the editor object anyway. The exception ended up being caught by the editor so it didn't impact functionality but this still logged an "uncaught exception" in the status of the extension.

@leops leops merged commit 99f59bf into main Nov 9, 2022
@leops leops deleted the feature/vscode-status-version branch November 9, 2022 10:59
@leops leops added E-VScode Editors: VSCode A-Editors Area: editors labels Nov 9, 2022
@leops leops added this to the 10.0.1 milestone Nov 9, 2022
jeysal added a commit to jeysal/rometools that referenced this pull request Nov 9, 2022
* upstream/main:
  fix(rome_js_analyze): Verify method name of React API calls (rome#3619)
  benchmark: Add pprettier and dprint to benchmark (rome#3597)
  feat(vscode): display the version of the language server in the status bar (rome#3616)
  fix(rome_cli): correctly account for diff diagnostics in the printed diagnostics count (rome#3595)
  fix(rome_cli): Respect formatter/linter `enabled` from configuration (rome#3591)
  Remove dead styles
  [website] Add scroll-padding-top
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A-Editors Area: editors E-VScode Editors: VSCode
Projects
None yet
Development

Successfully merging this pull request may close these issues.

📎 Show Server Version number in status bar
2 participants