blob: c107deda7bdb2d23451df1cf8f414aa6871588c0 [file] [log] [blame]
Martin Roth0ad5fbd2020-12-24 12:06:38 -07001#!/usr/bin/env sh
Martin Rothe99a7182018-06-06 21:34:47 -06002#
Patrick Georgi7333a112020-05-08 20:48:04 +02003# SPDX-License-Identifier: GPL-2.0-only
4
Martin Rothe99a7182018-06-06 21:34:47 -06005# DESCR: Check for illegal characters in filename
6
Martin Rothd81debd2022-06-03 00:06:57 -06007LINTDIR="$(
8 cd -- "$(dirname "$0")" > /dev/null 2>&1 || return
9 pwd -P
10)"
Martin Rothe99a7182018-06-06 21:34:47 -060011
Martin Rothd81debd2022-06-03 00:06:57 -060012# shellcheck source=helper_functions.sh
13. "${LINTDIR}/helper_functions.sh"
14
15# Exit if the code isn't in a git repo
16if [ "${IN_GIT_TREE}" -eq 0 ]; then
17 exit 0
Martin Rothe99a7182018-06-06 21:34:47 -060018fi
Martin Rothd81debd2022-06-03 00:06:57 -060019
20${FIND_FILES} | grep "[^A-Za-z0-9/_\.-]"