So that we don't have to manually update (or forget to do so) when
the mininum required version changes.

Signed-off-by: Cleber Rosa <[email protected]>
---
 server/autotest_remote.py |   13 ++++++++++---
 1 file changed, 10 insertions(+), 3 deletions(-)

diff --git a/server/autotest_remote.py b/server/autotest_remote.py
index 375ab83..704ce5f 100644
--- a/server/autotest_remote.py
+++ b/server/autotest_remote.py
@@ -170,9 +170,16 @@ class BaseAutotest(installable_object.InstallableObject):
         light_files = [os.path.join(self.source_material, f)
                        for f in os.listdir(self.source_material)
                        if f not in dirs_to_exclude]
-        # needs updating when grubby version is changed
-        light_files.append(os.path.join(self.source_material,
-                           "deps/grubby/grubby-8.13.tar.bz2"))
+
+        # there should be one and only one grubby tarball
+        grubby_glob = os.path.join(self.source_material,
+                                   "deps/grubby/grubby-*.tar.bz2")
+        grubby_tarball_paths = glob.glob(grubby_glob)
+        if grubby_tarball_paths:
+            grubby_tarball_path = grubby_tarball_paths[0]
+            if os.path.exists(grubby_tarball_path):
+                light_files.append(grubby_tarball_path)
+
         host.send_file(light_files, autodir, delete_dest=True)
 
         profilers_autodir = os.path.join(autodir, 'profilers')
-- 
1.7.10.4

_______________________________________________
Autotest mailing list
[email protected]
http://test.kernel.org/cgi-bin/mailman/listinfo/autotest

Reply via email to