mirror of
https://github.com/ben-grande/qusal.git
synced 2024-10-01 02:35:49 -04:00
20 lines
435 B
Bash
Executable File
20 lines
435 B
Bash
Executable File
#!/bin/sh
|
|
## SPDX-FileCopyrightText: 2024 Benjamin Grande M. S. <ben.grande.b@gmail.com>
|
|
##
|
|
## SPDX-License-Identifier: AGPL-3.0-or-later
|
|
|
|
set -eu
|
|
|
|
requires_program=""
|
|
for pkg in "${@}"; do
|
|
if ! command -v "${pkg}" >/dev/null; then
|
|
requires_program="${requires_program:+"${requires_program} "}${pkg}"
|
|
continue
|
|
fi
|
|
done
|
|
|
|
if test -n "${requires_program}"; then
|
|
echo "Missing program(s): ${requires_program}" >&2
|
|
exit 1
|
|
fi
|