feat: universal CLI packaging with arbitrary tools and Windows support #38
+1,091
−134
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
This PR transitions Ralph into a proper universal CLI package that can be installed globally and run from any directory. It migrates the core logic from Bash ("ralph.sh") to a cross-platform Node.js implementation ("ralph.js") and introduces flexible command-line arguments for advanced workflows.
Key Changes:
package.jsonwithbinmapping. Supportsnpm install -g ..ralph.shwith a normalizedralph.jsentrypoint, reducing dependencies (no longer requiresjqorbash).--tool <command>to allow any AI tool beyondampandclaude.--tool-args <arg>to pass flags directly to the underlying tool (e.g.,--printfor Claude Code).--prompt-file <path>to specify alternative instruction templates.node_modulespaths.getHelpText()triggered by-h,--help, or running without arguments.process.cwd()as the default base directory.Test Plan
node ralph.test.jsnpm install -g .ralph --help.ralph --tool echo --tool-args "hello world" 1.