Skip to content

Add Bash script support#1217

Open
Omar-Elwazeery wants to merge 1 commit into
colbymchenry:mainfrom
Omar-Elwazeery:feat/bash-script-support
Open

Add Bash script support#1217
Omar-Elwazeery wants to merge 1 commit into
colbymchenry:mainfrom
Omar-Elwazeery:feat/bash-script-support

Conversation

@Omar-Elwazeery

Copy link
Copy Markdown

Summary

Fixes #1203.

  • Register Bash/shell as a supported Tree-sitter language using the existing WASM grammar pipeline.
  • Add Bash detection for .sh, .bash, .bats, and extensionless scripts with Bash/POSIX shell shebangs.
  • Add a Bash extractor for shell functions, assignments, exported/readonly variables, command calls, and static source/script imports.
  • Include extensionless Bash shebang scripts in scan/sync flows and add Bash import resolution for shell/Bats files.
  • Add regression coverage for detection, extraction, scanning, sync, and .bats import resolution.

Testing

  • npm test -- __tests__/extraction.test.ts __tests__/resolution.test.ts __tests__/sync.test.ts -t Bash
  • npm run build
  • ⚠️ npm test currently times out in the full-suite parallel run at __tests__/mcp-daemon.test.ts > proxy survives the daemon dying mid-session and keeps serving (#662). I confirmed the same full-suite timeout occurs on a clean base after stashing this branch, and the exact test passes when run isolated both before and after this change.

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.

Feature Request: Bash Script Support for Code Graph Analysis

1 participant