Skip to content

Pashua's exit code is 0 after an error #18

Description

@phloggu

Pashua exits with zero even when loading a pashua template with errors. Pashua shows a dialog window describing the error, but does not exit non-zero. I would expect that the exit code is different from 0, when the program encounters an error of any kind.

Calling Pashua from within bash scripts, it would be useful to detect such failures and act accordingly. Since there are no variables set by Pashua after such an error and no output given neither after successful nor unsuccessful exit, an error can't be detected easily.

With an exit code, it would be easier:

pashua_run "my_template_with_errors.pashua"
if [ $? -ne 0 ]; then
  # treat error
elif [ $cb -eq 1 ]; then
  # cancel was pressed
...

Please introduce exit codes for Pashua. Thank you!

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions