Method: Bwrap::Execution::Labels.resolve_exit_code
- Defined in:
- lib/bwrap/execution/labels.rb
.resolve_exit_code(label) ⇒ Integer
Converts given label to real exit code.
Accepted labels:
-
:success
-
:unspecified
-
:generic
-
:target_host_not_found
-
:no_package_manager
-
:debootstrap_failed
-
:file_not_modified
Additional labels can be added with add_label.
49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 |
# File 'lib/bwrap/execution/labels.rb', line 49 def self.resolve_exit_code label return @additional_labels[label] if @additional_labels and @additional_labels[label] case label when :success NO_ERROR when :unspecified UNSPECIFIED_ERROR when :generic GENERIC_ERROR else warn "Got invalid error label: #{label}" INVALID_ERROR end end |