Skip to content

ci: add lint check to prevent single quotes in bootstrap scripts#22664

Merged
kacpersaw merged 2 commits into
mainfrom
kacpersaw/fix-bootstrap-single-quote-lint
Mar 6, 2026
Merged

ci: add lint check to prevent single quotes in bootstrap scripts#22664
kacpersaw merged 2 commits into
mainfrom
kacpersaw/fix-bootstrap-single-quote-lint

Conversation

@kacpersaw
Copy link
Copy Markdown

Problem

Bootstrap scripts under provisionersdk/scripts/ are inlined into templates via sh -c '${init_script}'. Any single quote (apostrophe) in these .sh files silently breaks the shell quoting, causing the agent to never start — with near-invisible error output.

Changes

  • scripts/check_bootstrap_quotes.sh — new lint script that scans all .sh files under provisionersdk/scripts/ for single quotes and fails with a clear error if any are found. Only checks shell scripts (not .ps1, which legitimately uses single quotes).
  • Makefile — added lint/bootstrap target wired into the lint dependency list.

Fixes #22062

Bootstrap scripts under provisionersdk/scripts/ are inlined into
templates via sh -c '${init_script}'. Any single quote character
in these .sh files silently breaks the shell quoting, preventing
agent startup.

Add scripts/check_bootstrap_quotes.sh that rejects single quotes
in bootstrap shell scripts, and wire it into make lint as
lint/bootstrap.

Fixes #22062
@kacpersaw kacpersaw requested a review from dannykopping March 6, 2026 11:37
Copy link
Copy Markdown
Contributor

@dannykopping dannykopping left a comment

Choose a reason for hiding this comment

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

Sweet, thanks!

@kacpersaw kacpersaw merged commit ba05188 into main Mar 6, 2026
24 checks passed
@kacpersaw kacpersaw deleted the kacpersaw/fix-bootstrap-single-quote-lint branch March 6, 2026 12:09
@github-actions github-actions Bot locked and limited conversation to collaborators Mar 6, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bug: single quotes in bootstrap scripts break agent startup for templates using sh -c inlining

2 participants