vsg-bridge-ls/showcase
Dandaedre 49d0eb6104
Add layered bridge configuration
2026-10-03 03:20:57 +02:00
..
README.md Add layered bridge configuration 2026-10-03 03:20:57 +02:00
demo_design.vhd Clarify formatter severity behavior 2026-10-03 01:15:03 +02:00
one-line-entity.vhd Add VSG correction actions 2026-10-03 00:44:40 +02:00
vsg.yaml Clarify formatter severity behavior 2026-10-03 01:15:03 +02:00

README.md

LSP showcase

These deliberately unformatted, valid VHDL files make the bridge behavior easy to inspect in an editor. Do not format and commit them: their findings are the showcase.

From the repository root, start your editor with the VSG environment active and pass the showcase configuration to the bridge:

[language-server.vsg_bridge_ls]
command = "vsg-bridge-ls"
args = [
  "--configuration", "/absolute/path/to/vsg-bridge-ls/showcase/vsg.yaml",
  # Uncomment to allow an action that opens rule documentation in a browser.
  # "--allow-browser-action",
  # Uncomment the next line to enable experimental individual rule fixes.
  # "--experimental-rule-fix",
  # Uncomment the next line to enable the experimental grouped line fix.
  # "--experimental-multi-rule-line-fix",
  # Uncomment the next line to expose debug information in hover and an action.
  # "--debug-mode",
]

[[language]]
name = "vhdl"
language-servers = ["vsg_bridge_ls"]
auto-format = false

Open one-line-entity.vhd first. It intentionally has multiple fixable rules on one line and rules from different VSG phases. You should be able to:

  1. See full-line diagnostics with exact VSG rule IDs.
  2. Hover the line for severity, phase, fixability, effective configuration, and documentation links.
  3. with --experimental-rule-fix, select an individual Quick Fix for one rule on line 1;
  4. select Fix all VSG findings to run the normal phase-seven formatter; and
  5. run Helix :format through the bridge's equivalent LSP formatting request.

To inspect the opt-in grouped action, add --experimental-multi-rule-line-fix to the bridge arguments. The action is clearly labelled Experimental. Enable both correction flags to display grouped and individual actions together.

Then open demo_design.vhd to inspect findings and fixes across an entity, port clause, architecture, operators, indentation, and identifier casing. The enabled comment_012 rule reports its TODO comment as a non-fixable Warning, so both LSP Error and Warning presentation can be inspected. VSG deliberately fixes only Error-severity rules; the warning remains after Fix all VSG findings, while one-line-entity.vhd becomes clean.

Restarting the language server should replace the existing diagnostic set, without doubling its entries. The bridge clears every open document during a graceful LSP shutdown so Helix can discard diagnostics owned by the old server instance.

Helix is the maintained test target. Its action picker is available through space then a; hover is space then k. Key bindings can vary by release.