Skip to content

BUG: zsh not supported #33

@Diwakar-Gupta

Description

@Diwakar-Gupta

Describe the bug

When using non-bash shell say zsh, shell does not open.

In file aquarium.py,
executing subprocess.call([SHELL, "--init-file", f"{aliases_file}", "-i"])
produces error
/usr/bin/zsh: no such option: init_file

this is because zsh dont support providing init-file yet.

Expected Results

  1. Since zsh don't support init-file, it should always start bash insteed
  2. we can start bash only when default shell is zsh ie. if SHELL.endswith('zsh').
  3. make it work for zsh

Solution1.

SHELL="/usr/bin/bash"
subprocess.call([SHELL, "--init-file", f"{aliases_file}", "-i"])

Solution2.

if SHELL.endswith('zsh'):
subprocess.call(["/usr/bin/bash", "--init-file", f"{aliases_file}", "-i"])
else:
subprocess.call([SHELL, "--init-file", f"{aliases_file}", "-i"])

Solution3.

since zsh dont support init-file this has to be done the hard-way.

Any solution to support zsh with aliases is most welcome.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions