summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorJoan Figueras2021-06-16 23:53:57 +0200
committerJoan Figueras2021-06-16 23:53:57 +0200
commitf5b046ebe9f2680f4c1abd6994a7d7ed0608571f (patch)
treeea167468e33ac49a1bd099ae6dfccde4138bb1cf /PKGBUILD
parent4bd9ffe3e4d0f83ef2b59663e715d379fd866a9c (diff)
downloadaur-f5b046ebe9f2680f4c1abd6994a7d7ed0608571f.tar.gz
Just in case myconfig is found but it's empty
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD2
1 files changed, 1 insertions, 1 deletions
diff --git a/PKGBUILD b/PKGBUILD
index 6c70927835fe..8bf6c0133182 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -165,7 +165,7 @@ prepare() {
# If we detect partial file with scripts/config commands, we execute as a script
# If not, it's a full config, will be replaced
for _myconfig in "${SRCDEST}/myconfig" "${HOME}/.config/linux-xanmod/myconfig" "${XDG_CONFIG_HOME}/linux-xanmod/myconfig" ; do
- if [ -f "${_myconfig}" ]; then
+ if [ -f "${_myconfig}" ] && [ "$(wc -l <"${_myconfig}")" -gt "0" ]; then
if grep -q 'scripts/config' "${_myconfig}"; then
# myconfig is a partial file. Executing as a script
msg2 "Applying myconfig..."