From c669d0c2627556e62892d8f9be771558364b6ed6 Mon Sep 17 00:00:00 2001 From: Reid 'arrdem' McKenzie Date: Mon, 28 Nov 2022 18:55:26 -0700 Subject: [PATCH] For backwards compat, guard against legacy files --- src/python/cram/v1.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/python/cram/v1.py b/src/python/cram/v1.py index 0709155..3ce9c8a 100644 --- a/src/python/cram/v1.py +++ b/src/python/cram/v1.py @@ -120,6 +120,7 @@ class LightPackageV1(PackageV1): class ProfileV1(PackageV1): """Unline packages, profiles don't support recursive stow of contents.""" + _LEGACY_SPECIAL_FILES = ["BUILD", "PRE_INSTALL", "INSTALL", "POST_INSTALL", "REQUIRES"] SPECIAL_FILES = [] _config = None @@ -127,10 +128,10 @@ class ProfileV1(PackageV1): return {} def test(self): - return self.root.is_dir() + return self.root.is_dir() and not any((self.root / f).exists() for f in self._LEGACY_SPECIAL_FILES) def do_install(self, fs: Vfs, dest: Path): - self.do_sh_or_script(self.config().get("package", {}).get("install"), fs, dest) + return def requires(self): requires = super().requires()