diff options
author | Oliver Smith <osmith@sysmocom.de> | 2022-09-23 12:30:43 +0200 |
---|---|---|
committer | osmith <osmith@sysmocom.de> | 2022-10-06 07:44:31 +0000 |
commit | a91667d04c5710057c8d8fbc460ca0fca387c563 (patch) | |
tree | 4e6a8968790d130abd9df8aeea6640082f549d4d | |
parent | ba8df68397526ca0e6a390fec754c12d219adc8e (diff) |
obs: build_srcpkg_if_needed: switch if branches
Make it slightly easier to read, before extending the latest branch with
master too in a follow-up patch.
Related: OS#2385
Change-Id: I4f1d4e250eb4d8163f1ded29106a44deb0d0feff
-rwxr-xr-x | scripts/obs/update_obs_project.py | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/scripts/obs/update_obs_project.py b/scripts/obs/update_obs_project.py index aa33984..168193d 100755 --- a/scripts/obs/update_obs_project.py +++ b/scripts/obs/update_obs_project.py @@ -66,9 +66,9 @@ def build_srcpkg_if_needed(proj, feed, branch, pkgs_remote, package, conflict_ve fetch, is_meta_pkg, skip_up_to_date): global srcpkgs_skipped - if feed != "latest": - print(f"{package}: building source package (feed is {feed})") - else: + if feed == "latest": + """ Check if we can skip this package by comparing the OBS version with + the git remote. """ if is_meta_pkg: latest_version = conflict_version if conflict_version else "1.0.0" else: @@ -95,6 +95,8 @@ def build_srcpkg_if_needed(proj, feed, branch, pkgs_remote, package, conflict_ve else: print(f"{package}: building source package (outdated:" f" {latest_version} <=> {obs_version} in OBS)") + else: + print(f"{package}: building source package (feed is {feed})") build_srcpkg(feed, branch, package, conflict_version, fetch, is_meta_pkg) |