Martin Roth | 0ad5fbd | 2020-12-24 12:06:38 -0700 | [diff] [blame] | 1 | #!/usr/bin/env sh |
Patrick Georgi | 55189c9 | 2020-05-10 20:09:31 +0200 | [diff] [blame] | 2 | # SPDX-License-Identifier: GPL-2.0-or-later |
Martin Roth | 44ef167 | 2016-02-02 09:43:12 -0700 | [diff] [blame] | 3 | # |
| 4 | # DESCR: Verify that site-local is not in the coreboot repository |
| 5 | # |
| 6 | # Because site-local is intended for local use only, it should never be |
| 7 | # pushed to coreboot.org. Even for committing it for local use, it's |
| 8 | # recommended that it be kept in a separate repository, and pulled in |
Martin Roth | d81debd | 2022-06-03 00:06:57 -0600 | [diff] [blame] | 9 | # as a submodule. |
Martin Roth | 44ef167 | 2016-02-02 09:43:12 -0700 | [diff] [blame] | 10 | |
Martin Roth | d81debd | 2022-06-03 00:06:57 -0600 | [diff] [blame] | 11 | LINTDIR="$( |
| 12 | cd -- "$(dirname "$0")" > /dev/null 2>&1 || return |
| 13 | pwd -P |
| 14 | )" |
Martin Roth | 44ef167 | 2016-02-02 09:43:12 -0700 | [diff] [blame] | 15 | |
Martin Roth | d81debd | 2022-06-03 00:06:57 -0600 | [diff] [blame] | 16 | # shellcheck source=helper_functions.sh |
| 17 | . "${LINTDIR}/helper_functions.sh" |
| 18 | |
| 19 | # Exit if the code isn't in a git repo |
| 20 | if [ "${IN_GIT_TREE}" -eq 0 ]; then |
| 21 | exit 0 |
| 22 | fi |
| 23 | |
| 24 | |
| 25 | if [ -n "$(${FIND_FILES} site-local/*)" ]; then |
| 26 | echo "Error: site-local must be kept separate from the coreboot repository." |
Martin Roth | 44ef167 | 2016-02-02 09:43:12 -0700 | [diff] [blame] | 27 | fi |