Skip to content

Unknown command always exits 0 #10

Description

@paul

In the error handler at https://github.com/terminalwire/ruby/blob/main/gem/terminalwire-rails/lib/terminalwire/rails.rb#L174, when a CLI user tries a command that doesn't exist or other invocation error, the command always does exit 0, instead of a non-zero exit code indicating an error.

Also, the error message is written to stdout instead of stderr, but this is less of a concern.

Also, tangentially related, there doesn't seem to be any way for the user to set context.exit. That handler is always going to set it to 1 or 0.

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