.\" $HeadURL$ $LastChangedRevision$ .\" .pso ade-config --format=man .so \*[ade_include_prefix]/ade.man .TH ADESHF 1 "ADE_APP_TOKEN_RELEASE_DATE_MAN" .ne 5 .SH NAME adeshf \- call an ADE shell function .br .ne 5 .SH SYNOPSIS .B adeshf \*[ade_standard_synopsis_component] .I function [ .I arguments \fR ... ] .br .ne 5 .SH DESCRIPTION .B Adeshf provides a command line interface to the ADE shell library. .br .ne 5 .SH CONFIGURATION None. .ne 5 .SH OPTIONS \*[ade_standard_options_component] .br .ne 5 .SH EXIT STATUS On success .B adeshf returns zero. On failure it returns non-zero and displays a diagnostic message. .br .ne 5 .SH FILES None. .br .ne 5 .SH ENVIRONMENT VARIABLES None. .ne 5 .SH EXAMPLES This first example shows what happens when an unknown function is called: .IP .nf .fam C .B adeshf \[aq]f\[aq] /home/alexis/dev/svnwcs/ade/bin/adeshf: line 61: f: command not found adeshf: ERROR: frame#0: application\[aq]s entry function (adeshf()) failed .fam T .fi .PP This second example shows the importance of returning sensible return codes: .IP .nf .fam C .B adeshf \[aq]f() { ade_err_error $ERRSTACK_REF ADE_ERR_MISC \[dq]deliberate error\[dq]; }; f\[aq] .fam T .fi .PP (Failure to return .B $ADE_ERR_FAIL meant that no need to dump the error stack was detected, so there was no output, despite an error frame having been added to the error stack.) This third example makes the same call but with the right return code: .IP .nf .fam C .B adeshf \[aq]f() { ade_err_error $ERRSTACK_REF ADE_ERR_MISC \[dq]deliberate error\[dq]; return $ADE_ERR_FAIL; }; f\[aq] adeshf: ERROR: frame#0: deliberate error adeshf: ERROR: frame#1: application\[aq]s entry function (adeshf()) failed .fam T .fi .PP This fourth example makes the same call but having first configured the stack dumper to dump only the top frame: .IP .nf .fam C .B adeshf \[aq]f() { ade_err_error $ERRSTACK_REF ADE_ERR_MISC \[dq]deliberate error\[dq]; return $ADE_ERR_FAIL; }; ade_err_resetstack $ERRSTACK_REF dumpall=false; f\[aq] adeshf: ERROR: deliberate error .fam T .fi .ne 5 .SH CAVEATS None. .br .ne 5 .SH STANDARDS This manual page documents version ADE_APP_TOKEN_RELEASE_ID of .B adeshf\fR. .br .ne 5 .SH SEE ALSO adeperlf(1), adepyf(1), ade-config(1) .br .ne 5 .SH AUTHOR ADE_APP_TOKEN_AUTHOR_NAME .br .ne 5 .SH COPYRIGHT & DISTRIBUTION POLICY Copyright (C) 2003-ADE_APP_TOKEN_RELEASE_YEAR ADE_APP_TOKEN_AUTHOR_NAME \*[ade_standard_copyright_component]