feat: surface the detected cliPath and tolerate CRLF skill files - #14
Open
daian2024 wants to merge 1 commit into
Open
feat: surface the detected cliPath and tolerate CRLF skill files#14daian2024 wants to merge 1 commit into
daian2024 wants to merge 1 commit into
Conversation
detectTabbit already resolves the stable tabbit-cli launcher path, but the tabbit_browser_install tool never exposed it: agents had to fall back to platform documentation and a connection probe. Report the resolved cliPath in the tool output schema, the ready message, and every result branch (ready/restart-required/background, cached copies included) so agents can invoke the launcher directly. stripFrontmatter assumed LF-only frontmatter, so on Windows checkouts (git autocrlf) the skill frontmatter was never stripped. Tolerate both LF and CRLF line endings and export the helper for direct testing.
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.
Summary
Two small improvements on top of the existing detection flow:
Expose the resolved launcher path (
cliPath) —detectTabbitalready resolves the stable tabbit-cli launcher (%LOCALAPPDATA%\Tabbit\LocalAgent\bin\tabbit-cli.exeon Windows,~/.local/bin/tabbit-clielsewhere), buttabbit_browser_installnever returned it. This PR addscliPathto the tool's output schema and to every result branch (ready / restart-required / background, including session-cached copies), and mentions it in the ready message. Agents can now invoke the launcher directly instead of guessing from platform docs.Tolerate CRLF skill files in
stripFrontmatter— the frontmatter stripper assumed LF-only line endings. On Windows checkouts (git autocrlf) the---frontmatter was never stripped, so the skill content served to models included the raw YAML header. The helper now detects LF vs CRLF and is exported for direct testing.Test plan
node --test: 34/34 pass (3 new tests: CRLF/LF frontmatter stripping,cliPathin tool result + cached copy, schema property).detectTabbit()returnsreadywithcliPathpointing at the stable LocalAgent entry and the Runtime process detected.