diff --git a/pmb/parse/apkbuild.py b/pmb/parse/apkbuild.py index fc2f71b5..7b733f21 100644 --- a/pmb/parse/apkbuild.py +++ b/pmb/parse/apkbuild.py @@ -96,8 +96,11 @@ def apkbuild(args, path): if path in args.cache["apkbuild"]: return args.cache["apkbuild"][path] + # Read the file and check line endings with open(path, encoding="utf-8") as handle: lines = handle.readlines() + if handle.newlines != '\n': + raise RuntimeError("Wrong line endings in APKBUILD: " + path) # Parse all attributes from the config ret = {}