Skip to content

Standardize Bash CLI entrypoints around .sh commands and per-command scripts#5

Merged
codeforester merged 1 commit intomainfrom
hpr/add-setup-script
Apr 12, 2026
Merged

Standardize Bash CLI entrypoints around .sh commands and per-command scripts#5
codeforester merged 1 commit intomainfrom
hpr/add-setup-script

Conversation

@codeforester
Copy link
Copy Markdown
Owner

Summary

This PR tightens the Bash CLI command conventions so the user-facing entrypoints and the command implementation layout are both explicit and self-identifying.

Bash commands now use .sh entrypoint symlinks in cli/bash/bin/, and command targets now resolve only from cli/bash/commands/<cli>/<cli>.sh. This removes the older main.sh-style ambiguity and makes the Bash side line up better with the planned Python CLI layout.

What Changed

  • updated bash-wrapper to treat .sh as the public Bash command suffix
  • changed wrapper dispatch to resolve commands only from:
    • cli/bash/commands/<cli>/<cli>.sh
  • removed support for cli/bash/commands/<cli>/main.sh
  • updated command listing to show Bash commands as *.sh
  • renamed Bash entrypoint symlinks in cli/bash/bin/ to use .sh
    • for example, setup.sh instead of setup
  • moved the setup command implementation to:
    • cli/bash/commands/setup/setup.sh
  • updated wrapper, setup, and stdlib tests to match the new convention
  • updated Bash CLI docs to reflect the new entrypoint and target naming rules

Why

This gives us a cleaner long-term separation between Bash and Python command surfaces:

  • Bash commands are visibly Bash commands at the entrypoint layer: setup.sh
  • Python commands can stay extensionless later without colliding conceptually with Bash commands
  • command implementation files are easier to identify in search results, stack traces, and reviews
  • the repo no longer accumulates many unrelated main.sh files with different responsibilities

Verification

Validated with:

bats cli/env/tests/banyanenv.bats \
     cli/bash/bin/tests/bash-wrapper.bats \
     cli/bash/commands/setup/tests/setup.bats \
     cli/bash/lib/std/tests/lib_std.bats

@codeforester codeforester merged commit 9a9854e into main Apr 12, 2026
0 of 3 checks passed
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.

1 participant