1ATF-SH(1)                 BSD General Commands Manual                ATF-SH(1)
2

NAME

4     atf-sh [-s shell] — interpreter for shell-based test programs
5

SYNOPSIS

7     atf-sh script
8

DESCRIPTION

10     atf-sh is an interpreter that runs the test program given in script after
11     loading the atf-sh(3) library.
12
13     atf-sh is not a real interpreter though: it is just a wrapper around the
14     system-wide shell defined by ATF_SHELL.  atf-sh executes the interpreter,
15     loads the atf-sh(3) library and then runs the script.  You must consider
16     atf-sh to be a POSIX shell by default and thus should not use any non-
17     standard extensions.
18
19     The following options are available:
20
21     -s shell     Specifies the shell to use instead of the value provided by
22                  ATF_SHELL.
23

ENVIRONMENT

25     ATF_LIBEXECDIR    Overrides the builtin directory where atf-sh is lo‐
26                       cated.  Should not be overridden other than for testing
27                       purposes.
28     ATF_PKGDATADIR    Overrides the builtin directory where libatf-sh.subr is
29                       located.  Should not be overridden other than for test‐
30                       ing purposes.
31     ATF_SHELL         Path to the system shell to be used in the generated
32                       scripts.  Scripts must not rely on this variable being
33                       set to select a specific interpreter.
34

EXAMPLES

36     Scripts using atf-sh(3) should start with:
37
38           #! /usr/bin/env atf-sh
39
40     Alternatively, if you want to explicitly choose a shell interpreter, you
41     cannot rely on env(1) to find atf-sh.  Instead, you have to hardcode the
42     path to atf-sh in the script and then use the -s option afterwards as a
43     single parameter:
44
45           #! /path/to/bin/atf-sh -s/bin/bash
46

SEE ALSO

48     atf-sh(3)
49
50BSD                           September 27, 2014                           BSD
Impressum