Forwarding error to std output in bash script now

This commit is contained in:
2024-04-30 14:48:01 +02:00
parent 9cc3641238
commit b089017f69

View File

@@ -4,7 +4,7 @@
necessary_packages=("pdflatex")
for package in ${necessary_packages}; do
if ! [dpkg -l ${package} > /dev/null]; then
if ! [dpkg -l ${package} > /dev/null 2>&1]; then
echo "Error: ${package} is not installed."
exit 1
fi