The trivial-shell Reference Manual

Table of Contents

Next: , Previous: , Up: (dir)   [Contents][Index]

The trivial-shell Reference Manual

This is the trivial-shell Reference Manual, version 0.2.0, generated automatically by Declt version 2.3 "Robert April" on Tue Feb 20 09:27:36 2018 GMT+0.


Next: , Previous: , Up: Top   [Contents][Index]

1 Systems

The main system appears first, followed by any subsystem dependency.


Previous: , Up: Systems   [Contents][Index]

1.1 trivial-shell

Maintainer

Gary Warren King <gwking@metabang.com>

Author

Gary Warren King <gwking@metabang.com>

License

MIT Style License

Description

OS and Implementation independent access to the shell

Version

0.2.0

Source

trivial-shell.asd (file)

Components

Next: , Previous: , Up: Top   [Contents][Index]

2 Modules

Modules are listed depth-first from the system components tree.


Next: , Previous: , Up: Modules   [Contents][Index]

2.1 trivial-shell/notes

Parent

trivial-shell (system)

Location

dev/

Component

notes.text (file)


Next: , Previous: , Up: Modules   [Contents][Index]

2.2 trivial-shell/timeout

Parent

trivial-shell (system)

Location

timeout/

Components

Next: , Previous: , Up: Modules   [Contents][Index]

2.3 trivial-shell/setup

Dependency

timeout (module)

Parent

trivial-shell (system)

Location

dev/

Component

package.lisp (file)


Next: , Previous: , Up: Modules   [Contents][Index]

2.4 trivial-shell/dev

Dependency

setup (module)

Parent

trivial-shell (system)

Location

dev/

Components

Next: , Previous: , Up: Modules   [Contents][Index]

2.5 trivial-shell/port

Dependency

dev (module)

Parent

trivial-shell (system)

Location

dev/

Component

sbcl.lisp (file)


Next: , Previous: , Up: Modules   [Contents][Index]

2.6 trivial-shell/website

Parent

trivial-shell (system)

Location

website/

Component

source (module)


Previous: , Up: Modules   [Contents][Index]

2.7 trivial-shell/website/source

Parent

website (module)

Location

website/source/

Component

index.md (file)


Next: , Previous: , Up: Top   [Contents][Index]

3 Files

Files are sorted by type and then listed depth-first from the systems components trees.


Next: , Previous: , Up: Files   [Contents][Index]

3.1 Lisp


Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.1 trivial-shell.asd

Location

trivial-shell.asd

Systems

trivial-shell (system)


Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.2 trivial-shell/timeout/package.lisp

Parent

timeout (module)

Location

timeout/package.lisp

Packages

com.metabang.trivial-timeout


Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.3 trivial-shell/timeout/with-timeout.lisp

Dependency

package.lisp (file)

Parent

timeout (module)

Location

timeout/with-timeout.lisp

Exported Definitions
Internal Definitions

Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.4 trivial-shell/setup/package.lisp

Parent

setup (module)

Location

dev/package.lisp

Packages

trivial-shell


Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.5 trivial-shell/dev/definitions.lisp

Parent

dev (module)

Location

dev/definitions.lisp

Exported Definitions

Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.6 trivial-shell/dev/macros.lisp

Parent

dev (module)

Location

dev/macros.lisp

Internal Definitions

Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.7 trivial-shell/dev/utilities.lisp

Parent

dev (module)

Location

dev/utilities.lisp

Internal Definitions

Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.8 trivial-shell/dev/shell.lisp

Dependencies
Parent

dev (module)

Location

dev/shell.lisp

Exported Definitions
Internal Definitions

Previous: , Up: Lisp files   [Contents][Index]

3.1.9 trivial-shell/port/sbcl.lisp

Parent

port (module)

Location

dev/sbcl.lisp

Internal Definitions

Previous: , Up: Files   [Contents][Index]

3.2 Other


Next: , Previous: , Up: Other files   [Contents][Index]

3.2.1 trivial-shell/notes/notes.text

Parent

notes (module)

Location

dev/notes.text


Previous: , Up: Other files   [Contents][Index]

3.2.2 trivial-shell/website/source/index.md

Parent

source (module)

Location

/home/quickbuilder/quicklisp/dists/quicklisp/software/trivial-shell-20170630-git/website/source/index.md (not found)


Next: , Previous: , Up: Top   [Contents][Index]

4 Packages

Packages are listed by definition order.


Next: , Previous: , Up: Packages   [Contents][Index]

4.1 com.metabang.trivial-timeout

Source

package.lisp (file)

Nickname

trivial-timeout

Use List

common-lisp

Used By List

trivial-shell

Exported Definitions
Internal Definitions

Previous: , Up: Packages   [Contents][Index]

4.2 trivial-shell

Source

package.lisp (file)

Nicknames
Use List
Exported Definitions
Internal Definitions

Next: , Previous: , Up: Top   [Contents][Index]

5 Definitions

Definitions are sorted by export status, category, package, and then by lexicographic order.


Next: , Previous: , Up: Definitions   [Contents][Index]

5.1 Exported definitions


Next: , Previous: , Up: Exported definitions   [Contents][Index]

5.1.1 Special variables

Special Variable: *bourne-compatible-shell*

The path to a Bourne compatible command shell in physical pathname notation.

Package

trivial-shell

Source

definitions.lisp (file)

Special Variable: *shell-search-paths*
Package

trivial-shell

Source

definitions.lisp (file)


Next: , Previous: , Up: Exported definitions   [Contents][Index]

5.1.2 Macros

Macro: with-timeout (SECONDS) &body BODY

Execute ‘body‘ for no more than ‘seconds‘ time.

If ‘seconds‘ is exceeded, then a [timeout-error][] will be signaled.

If ‘seconds‘ is nil, then the body will be run normally until it completes or is interrupted.

Package

com.metabang.trivial-timeout

Source

with-timeout.lisp (file)


Next: , Previous: , Up: Exported definitions   [Contents][Index]

5.1.3 Functions

Function: exit &optional CODE

Exit the process. CODE is either a numeric exit code, or the special values :SUCCESS or :FAILURE, which maps to the appropriate exit codes for the operating system.

Package

trivial-shell

Source

shell.lisp (file)

Function: get-env-var NAME

Return the value of the environment variable ‘name‘.

Package

trivial-shell

Source

shell.lisp (file)


Next: , Previous: , Up: Exported definitions   [Contents][Index]

5.1.4 Generic functions

Generic Function: shell-command COMMAND &key INPUT
Package

trivial-shell

Methods
Method: shell-command COMMAND &key INPUT

Synchronously execute ‘command‘ using a Bourne-compatible shell, returns (values output error-output exit-status).

The ‘command‘ can be a full path to a shell executable binary
or just its name. In the later case, the variable ‘*shell-search-paths*‘ will be used to find the executable.

Depending on the implementation, the variable ‘*bourne-compatible-shell*‘ may be used to find a shell to use in executing ‘command‘.

Source

shell.lisp (file)

Method: shell-command (COMMAND pathname) &key INPUT
Source

shell.lisp (file)


Previous: , Up: Exported definitions   [Contents][Index]

5.1.5 Conditions

Condition: timeout-error ()

An error signaled when the duration specified in the [with-timeout][] is exceeded.

Package

com.metabang.trivial-timeout

Source

with-timeout.lisp (file)

Direct superclasses

error (condition)


Previous: , Up: Definitions   [Contents][Index]

5.2 Internal definitions


Next: , Previous: , Up: Internal definitions   [Contents][Index]

5.2.1 Special variables

Special Variable: *os-alist*
Package

trivial-shell

Source

utilities.lisp (file)


Next: , Previous: , Up: Internal definitions   [Contents][Index]

5.2.2 Macros

Macro: with-gensyms SYMS &body BODY
Package

trivial-shell

Source

macros.lisp (file)

Macro: with-input (VAR SOURCE &rest ARGS) &body BODY

Create an input stream from source and bind it to var within the body of the with-input form. The stream will be closed if necessary on exit.

Package

trivial-shell

Source

macros.lisp (file)

Macro: with-output (VAR DESTINATION &rest ARGS) &body BODY

Create an output stream from source and bind it to var within the body of the with-output form. The stream will be closed if necessary on exit.

Package

trivial-shell

Source

macros.lisp (file)

Macro: with-stream-from-specifier (STREAM STREAM-SPECIFIER DIRECTION &rest ARGS) &body BODY
Package

trivial-shell

Source

macros.lisp (file)


Next: , Previous: , Up: Internal definitions   [Contents][Index]

5.2.3 Functions

Function: %exit CODE
Package

trivial-shell

Source

sbcl.lisp (file)

Function: %get-env-var NAME
Package

trivial-shell

Source

sbcl.lisp (file)

Function: %os-process-id ()
Package

trivial-shell

Source

sbcl.lisp (file)

Function: %shell-command COMMAND INPUT
Package

trivial-shell

Source

sbcl.lisp (file)

Function: %shell-command-using-temporary-file COMMAND INPUT
Package

trivial-shell

Source

sbcl.lisp (file)

Function: build-with-timeout SECONDS BODY
Package

com.metabang.trivial-timeout

Source

with-timeout.lisp (file)

Function: create-shell-process COMMAND WAIT
Package

trivial-shell

Source

sbcl.lisp (file)

Function: directory-pathname-p PATHNAME

Does ‘pathname‘ syntactically represent a directory?

A directory-pathname is a pathname _without_ a filename. The three ways that the filename components can be missing are for it to be ‘nil‘, ‘:unspecific‘ or the empty string.

Package

trivial-shell

Source

utilities.lisp (file)

Function: find-command-ending-in-string COMMAND
Package

trivial-shell

Source

shell.lisp (file)

Function: generate-platform-specific-code SECONDS-SYMBOL DOIT-SYMBOL
Package

com.metabang.trivial-timeout

Source

with-timeout.lisp (file)

Function: host-os ()
Package

trivial-shell

Source

utilities.lisp (file)

Function: open-temporary-file ()
Package

trivial-shell

Source

sbcl.lisp (file)

Function: os-process-id ()

Return the process-id of the currently executing OS process.

Package

trivial-shell

Source

shell.lisp (file)

Function: process-alive-p PROCESS
Package

trivial-shell

Source

sbcl.lisp (file)

Function: process-exit-code PROCESS
Package

trivial-shell

Source

sbcl.lisp (file)

Function: read-temporary-file FILE-STREAM
Package

trivial-shell

Source

sbcl.lisp (file)

Function: symbol-if-external NAME PACKAGE
Package

trivial-shell

Source

sbcl.lisp (file)


Previous: , Up: Internal definitions   [Contents][Index]

5.2.4 Generic functions

Generic Function: close-stream-specifier STEAM

Close a stream and handle other bookkeeping as appropriate.

Package

trivial-shell

Source

macros.lisp (file)

Methods
Method: close-stream-specifier (S string-stream)
Method: close-stream-specifier S
Generic Function: file-to-string-as-lines PATHNAME
Package

trivial-shell

Source

shell.lisp (file)

Methods
Method: file-to-string-as-lines (STREAM stream)
Method: file-to-string-as-lines (PATHNAME pathname)
Generic Function: make-stream-from-specifier SPECIFIER DIRECTION &rest ARGS

Create and return a stream from specifier, direction and any other argsuments

Package

trivial-shell

Source

macros.lisp (file)

Methods
Method: make-stream-from-specifier (STREAM-SPECIFIER string) (DIRECTION (eql output)) &rest ARGS
Method: make-stream-from-specifier (STREAM-SPECIFIER string) (DIRECTION symbol) &rest ARGS
Method: make-stream-from-specifier (STREAM-SPECIFIER pathname) (DIRECTION symbol) &rest ARGS
Method: make-stream-from-specifier (STREAM-SPECIFIER (eql none)) (DIRECTION symbol) &rest ARGS
Method: make-stream-from-specifier (STREAM-SPECIFIER (eql nil)) (DIRECTION symbol) &rest ARGS
Method: make-stream-from-specifier (STREAM-SPECIFIER (eql t)) (DIRECTION symbol) &rest ARGS
Method: make-stream-from-specifier (STREAM-SPECIFIER stream) (DIRECTION symbol) &rest ARGS

Previous: , Up: Top   [Contents][Index]

Appendix A Indexes


Next: , Previous: , Up: Indexes   [Contents][Index]

A.1 Concepts

Jump to:   F   L   M   O   T  
Index Entry  Section

F
File, Lisp, trivial-shell.asd: The trivial-shell<dot>asd file
File, Lisp, trivial-shell/dev/definitions.lisp: The trivial-shell/dev/definitions<dot>lisp file
File, Lisp, trivial-shell/dev/macros.lisp: The trivial-shell/dev/macros<dot>lisp file
File, Lisp, trivial-shell/dev/shell.lisp: The trivial-shell/dev/shell<dot>lisp file
File, Lisp, trivial-shell/dev/utilities.lisp: The trivial-shell/dev/utilities<dot>lisp file
File, Lisp, trivial-shell/port/sbcl.lisp: The trivial-shell/port/sbcl<dot>lisp file
File, Lisp, trivial-shell/setup/package.lisp: The trivial-shell/setup/package<dot>lisp file
File, Lisp, trivial-shell/timeout/package.lisp: The trivial-shell/timeout/package<dot>lisp file
File, Lisp, trivial-shell/timeout/with-timeout.lisp: The trivial-shell/timeout/with-timeout<dot>lisp file
File, other, trivial-shell/notes/notes.text: The trivial-shell/notes/notes<dot>text file
File, other, trivial-shell/website/source/index.md: The trivial-shell/website/source/index<dot>md file

L
Lisp File, trivial-shell.asd: The trivial-shell<dot>asd file
Lisp File, trivial-shell/dev/definitions.lisp: The trivial-shell/dev/definitions<dot>lisp file
Lisp File, trivial-shell/dev/macros.lisp: The trivial-shell/dev/macros<dot>lisp file
Lisp File, trivial-shell/dev/shell.lisp: The trivial-shell/dev/shell<dot>lisp file
Lisp File, trivial-shell/dev/utilities.lisp: The trivial-shell/dev/utilities<dot>lisp file
Lisp File, trivial-shell/port/sbcl.lisp: The trivial-shell/port/sbcl<dot>lisp file
Lisp File, trivial-shell/setup/package.lisp: The trivial-shell/setup/package<dot>lisp file
Lisp File, trivial-shell/timeout/package.lisp: The trivial-shell/timeout/package<dot>lisp file
Lisp File, trivial-shell/timeout/with-timeout.lisp: The trivial-shell/timeout/with-timeout<dot>lisp file

M
Module, trivial-shell/dev: The trivial-shell/dev module
Module, trivial-shell/notes: The trivial-shell/notes module
Module, trivial-shell/port: The trivial-shell/port module
Module, trivial-shell/setup: The trivial-shell/setup module
Module, trivial-shell/timeout: The trivial-shell/timeout module
Module, trivial-shell/website: The trivial-shell/website module
Module, trivial-shell/website/source: The trivial-shell/website/source module

O
Other File, trivial-shell/notes/notes.text: The trivial-shell/notes/notes<dot>text file
Other File, trivial-shell/website/source/index.md: The trivial-shell/website/source/index<dot>md file

T
trivial-shell.asd: The trivial-shell<dot>asd file
trivial-shell/dev: The trivial-shell/dev module
trivial-shell/dev/definitions.lisp: The trivial-shell/dev/definitions<dot>lisp file
trivial-shell/dev/macros.lisp: The trivial-shell/dev/macros<dot>lisp file
trivial-shell/dev/shell.lisp: The trivial-shell/dev/shell<dot>lisp file
trivial-shell/dev/utilities.lisp: The trivial-shell/dev/utilities<dot>lisp file
trivial-shell/notes: The trivial-shell/notes module
trivial-shell/notes/notes.text: The trivial-shell/notes/notes<dot>text file
trivial-shell/port: The trivial-shell/port module
trivial-shell/port/sbcl.lisp: The trivial-shell/port/sbcl<dot>lisp file
trivial-shell/setup: The trivial-shell/setup module
trivial-shell/setup/package.lisp: The trivial-shell/setup/package<dot>lisp file
trivial-shell/timeout: The trivial-shell/timeout module
trivial-shell/timeout/package.lisp: The trivial-shell/timeout/package<dot>lisp file
trivial-shell/timeout/with-timeout.lisp: The trivial-shell/timeout/with-timeout<dot>lisp file
trivial-shell/website: The trivial-shell/website module
trivial-shell/website/source: The trivial-shell/website/source module
trivial-shell/website/source/index.md: The trivial-shell/website/source/index<dot>md file

Jump to:   F   L   M   O   T  

Next: , Previous: , Up: Indexes   [Contents][Index]

A.2 Functions

Jump to:   %  
B   C   D   E   F   G   H   M   O   P   R   S   W  
Index Entry  Section

%
%exit: Internal functions
%get-env-var: Internal functions
%os-process-id: Internal functions
%shell-command: Internal functions
%shell-command-using-temporary-file: Internal functions

B
build-with-timeout: Internal functions

C
close-stream-specifier: Internal generic functions
close-stream-specifier: Internal generic functions
close-stream-specifier: Internal generic functions
create-shell-process: Internal functions

D
directory-pathname-p: Internal functions

E
exit: Exported functions

F
file-to-string-as-lines: Internal generic functions
file-to-string-as-lines: Internal generic functions
file-to-string-as-lines: Internal generic functions
find-command-ending-in-string: Internal functions
Function, %exit: Internal functions
Function, %get-env-var: Internal functions
Function, %os-process-id: Internal functions
Function, %shell-command: Internal functions
Function, %shell-command-using-temporary-file: Internal functions
Function, build-with-timeout: Internal functions
Function, create-shell-process: Internal functions
Function, directory-pathname-p: Internal functions
Function, exit: Exported functions
Function, find-command-ending-in-string: Internal functions
Function, generate-platform-specific-code: Internal functions
Function, get-env-var: Exported functions
Function, host-os: Internal functions
Function, open-temporary-file: Internal functions
Function, os-process-id: Internal functions
Function, process-alive-p: Internal functions
Function, process-exit-code: Internal functions
Function, read-temporary-file: Internal functions
Function, symbol-if-external: Internal functions

G
generate-platform-specific-code: Internal functions
Generic Function, close-stream-specifier: Internal generic functions
Generic Function, file-to-string-as-lines: Internal generic functions
Generic Function, make-stream-from-specifier: Internal generic functions
Generic Function, shell-command: Exported generic functions
get-env-var: Exported functions

H
host-os: Internal functions

M
Macro, with-gensyms: Internal macros
Macro, with-input: Internal macros
Macro, with-output: Internal macros
Macro, with-stream-from-specifier: Internal macros
Macro, with-timeout: Exported macros
make-stream-from-specifier: Internal generic functions
make-stream-from-specifier: Internal generic functions
make-stream-from-specifier: Internal generic functions
make-stream-from-specifier: Internal generic functions
make-stream-from-specifier: Internal generic functions
make-stream-from-specifier: Internal generic functions
make-stream-from-specifier: Internal generic functions
make-stream-from-specifier: Internal generic functions
Method, close-stream-specifier: Internal generic functions
Method, close-stream-specifier: Internal generic functions
Method, file-to-string-as-lines: Internal generic functions
Method, file-to-string-as-lines: Internal generic functions
Method, make-stream-from-specifier: Internal generic functions
Method, make-stream-from-specifier: Internal generic functions
Method, make-stream-from-specifier: Internal generic functions
Method, make-stream-from-specifier: Internal generic functions
Method, make-stream-from-specifier: Internal generic functions
Method, make-stream-from-specifier: Internal generic functions
Method, make-stream-from-specifier: Internal generic functions
Method, shell-command: Exported generic functions
Method, shell-command: Exported generic functions

O
open-temporary-file: Internal functions
os-process-id: Internal functions

P
process-alive-p: Internal functions
process-exit-code: Internal functions

R
read-temporary-file: Internal functions

S
shell-command: Exported generic functions
shell-command: Exported generic functions
shell-command: Exported generic functions
symbol-if-external: Internal functions

W
with-gensyms: Internal macros
with-input: Internal macros
with-output: Internal macros
with-stream-from-specifier: Internal macros
with-timeout: Exported macros

Jump to:   %  
B   C   D   E   F   G   H   M   O   P   R   S   W  

Next: , Previous: , Up: Indexes   [Contents][Index]

A.3 Variables

Jump to:   *  
S  
Index Entry  Section

*
*bourne-compatible-shell*: Exported special variables
*os-alist*: Internal special variables
*shell-search-paths*: Exported special variables

S
Special Variable, *bourne-compatible-shell*: Exported special variables
Special Variable, *os-alist*: Internal special variables
Special Variable, *shell-search-paths*: Exported special variables

Jump to:   *  
S  

Previous: , Up: Indexes   [Contents][Index]

A.4 Data types

Jump to:   C   P   S   T  
Index Entry  Section

C
com.metabang.trivial-timeout: The com<dot>metabang<dot>trivial-timeout package
Condition, timeout-error: Exported conditions

P
Package, com.metabang.trivial-timeout: The com<dot>metabang<dot>trivial-timeout package
Package, trivial-shell: The trivial-shell package

S
System, trivial-shell: The trivial-shell system

T
timeout-error: Exported conditions
trivial-shell: The trivial-shell system
trivial-shell: The trivial-shell package

Jump to:   C   P   S   T