Same than recipetool, the default revision is set to AUTOREV regardless
of the URI scheme. AUTOREV is now the default value only if the source URI
supports SRCREV.

Signed-off-by: Corentin Guillevic <[email protected]>
---
 scripts/lib/devtool/upgrade.py | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/scripts/lib/devtool/upgrade.py b/scripts/lib/devtool/upgrade.py
index 8930fde5d6..34e23c2c45 100644
--- a/scripts/lib/devtool/upgrade.py
+++ b/scripts/lib/devtool/upgrade.py
@@ -157,7 +157,12 @@ def _get_uri(rd):
             break
     if not srcuri:
         raise DevtoolError('Unable to find non-local entry in SRC_URI')
-    srcrev = '${AUTOREV}'
+
+    if srcuri and srcuri.startswith(('gitsm://', 'git://', 'hg://', 'svn://')):
+        srcrev = '${AUTOREV}'
+    else:
+        srcrev = None
+
     if '://' in srcuri:
         # Fetch a URL
         rev_re = re.compile(';rev=([^;]+)')
-- 
2.51.0

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#232374): 
https://lists.openembedded.org/g/openembedded-core/message/232374
Mute This Topic: https://lists.openembedded.org/mt/118130046/21656
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to