Skip to content

Support Bash/Zsh-aware project activation #747

@codeforester

Description

@codeforester

Context

basectl activate currently starts a Base-managed Bash runtime shell regardless of the caller login shell. That is deliberate today because the activation runtime is implemented around lib/bash/runtime/bashrc, Bash sourcing semantics, and Bash-compatible project activation scripts.

We should keep the current behavior stable, but consider a future design where Base can support both Bash and Zsh activation ergonomically.

Proposed direction

  • Make base_init.sh compatible with both Bash and Zsh where practical.
  • Keep project-owned activation scripts under project control. Base should not try to make arbitrary project activate.source files shell-neutral unless the project opts into that convention.
  • Support only Bash and Zsh as first-class interactive activation shells.
  • If the user login shell is neither Bash nor Zsh, default activation should continue to use Bash.
  • Preserve Bash as the stable fallback and compatibility path.

Design questions

  • Should activation default to the login shell when it is Bash or Zsh, or should this be controlled by an explicit --shell bash|zsh|login option?
  • Should manifest activate.source entries become shell-tagged, for example Bash-only, Zsh-only, or shared?
  • Should Base provide a separate lib/zsh/runtime/zshrc that mirrors the Bash runtime contract?
  • How should prompt ownership work when the activated shell is Zsh?
  • What is the compatibility boundary for shell-specific aliases, completions, options, and user dotfiles?

Acceptance criteria

  • A future design document or implementation plan defines the activation shell contract for Bash and Zsh.
  • Bash activation remains backward compatible.
  • Non-Bash/non-Zsh login shells fall back to Bash.
  • Zsh support, if implemented, has dedicated runtime tests and documentation.
  • Documentation clearly explains the supported shells and the project-owned activation-script boundary.

Metadata

Metadata

Assignees

Labels

enhancementNew feature or product improvement

Type

No type
No fields configured for issues without a type.

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions