Skip to content

Commit

Permalink
misc: check that astyle exists
Browse files Browse the repository at this point in the history
Signed-off-by: Ivan Velickovic <[email protected]>
  • Loading branch information
Ivan-Velickovic committed Jul 15, 2024
1 parent f43fe93 commit 91c8795
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions misc/style-c.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,13 @@
#
# SPDX-License-Identifier: BSD-2-Clause
#
set -e

if ! command -v astyle >/dev/null 2>&1
then
echo "astyle could not be found, it must be available to run the script."
exit 1
fi

# Format (in place) a list of files as C code.
astyle --options="${0%/*}/astylerc" "$@"
Expand Down

0 comments on commit 91c8795

Please sign in to comment.