From c8a97b5184d534b41d6c26e8f0fba56b39e2b573 Mon Sep 17 00:00:00 2001 From: Patrick McDermott Date: Thu, 27 Dec 2018 19:31:59 -0500 Subject: ob_error(): Document --- (limited to 'lib') diff --git a/lib/output.sh b/lib/output.sh index cc6fa4b..7f5e54f 100644 --- a/lib/output.sh +++ b/lib/output.sh @@ -1,6 +1,6 @@ # Functions for printing messages # -# Copyright (C) 2012 Patrick McDermott +# Copyright (C) 2012, 2018 Patrick McDermott # # This file is part of opkbuild. # @@ -17,6 +17,17 @@ # You should have received a copy of the GNU General Public License # along with opkbuild. If not, see . +## @brief Print an error message and exit +## @details \fBob_error\fP prints \fIarguments\fP according to \fIformat\fP and +## then exits the application. +## @operand format req The format string. See \fBprintf\fP(1) for the syntax +## of \fIformat\fP. +## @operand arguments opt Arguments to be printed, as referenced by +## \fIformat\fP. +## @return This function does not return. It causes the application to exit +## with an exit status of 1. +## @stderr This function prints the formatted error message to stderr. +## @pure no This function causes the current shell to exit. ob_error() { printf '%s: Error: ' "${0##*/}" >&2 -- cgit v0.9.1