feat(code-block-tools): restore shuck as a built-in shell linter#729
Open
soy-chrislo wants to merge 1 commit into
Open
feat(code-block-tools): restore shuck as a built-in shell linter#729soy-chrislo wants to merge 1 commit into
soy-chrislo wants to merge 1 commit into
Conversation
shuck was previously removed as a built-in because the released CLI had no stdin support (`check -` was treated as a literal filename). That blocker cleared in shuck v0.0.43 (ewhauser/shuck#1123), so this restores the `shuck` registry entry as a `shellcheck` alternative for `check` only. `shuck format` is left out for now since it is marked experimental upstream and requires `SHUCK_EXPERIMENTAL=1`, which no current built-in needs. Verified against a real shuck v0.0.43 binary: output goes to stdout, exits 1 on findings / 0 clean, and parses through the existing generic diagnostic parser without changes. Ref: rvben#655
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
shuck was previously removed as a built-in because the released CLI had no
stdin support:
shuck check -treated-as a literal filename instead ofreading the piped script. That got fixed upstream in shuck v0.0.43
(ewhauser/shuck#1123), so this restores the
shuckregistry entry as ashellcheckalternative.This PR only covers
check(lint), notformat. That split was discussedand agreed in #655:
formatis still flagged experimental upstream and needsSHUCK_EXPERIMENTAL=1to run, and rather than adding env-var plumbing tobuilt-in tool definitions for an experimental feature, the call was to hold
off on it until shuck drops that gate. #655 stays open to track that half.
I verified this against a real shuck v0.0.43 binary before opening this:
--output-format conciselines up with the genericfile:line:col: messageparser rumdl already uses for the other built-in tools, so nothing extra
was needed there
Type of Change
Testing
shuck_lints_shellintests/integration/code_block_tools_execution_test.rs, added toVERIFIED(gated by
every_builtin_tool_is_verified_or_exempt)make test-dev)shuckv0.0.43binary in
PATH(not skipped byrequire_tool!)Checklist
cargo fmt,cargo clippy --all-targets -- -D warnings)docs/code-block-tools.mdregenerated viamake sync-code-block-tools)Ref: #655 — left open intentionally;
shuck formatsupport istracked there as a follow-up once shuck removes the experimental gate.