badcmd: don't print "no context given"

Signed-off-by: Leah Rowe <leah@libreboot.org>
20240612_branch
Leah Rowe 2024-06-03 08:26:04 +01:00
parent 49ae4f91f9
commit c2793e7a5e
1 changed files with 3 additions and 3 deletions

View File

@ -17,12 +17,12 @@ err="err_"
badcmd()
{
errmsg="no context given"
[ $# -gt 0 ] && errmsg="$1"
errmsg="Bad command"
[ $# -gt 0 ] && errmsg="Bad command ($1)"
dstr="See $projectname build system docs: ${projectsite}docs/maintain/"
[ -d "docs" ] && dstr="$dstr (local docs available via docs/)"
$err "Bad command ($errmsg). $dstr"
$err "$errmsg. $dstr"
}
err_()
{