Bläddra i källkod

[cvs] Allow to checkout by date and time
With putting YYYYYMMDDHHmm into the SRCDATE bitbake will checkout
using "-D YYYYMMDD HH:mm UTC". Be careful when you switch from SRCDATE
with time and without to always get updatable packages.

Holger Hans Peter Freyther 16 år sedan
förälder
incheckning
7edb5f6d85
2 ändrade filer med 6 tillägg och 1 borttagningar
  1. 1 0
      ChangeLog
  2. 5 1
      lib/bb/fetch/cvs.py

+ 1 - 0
ChangeLog

@@ -142,6 +142,7 @@ Changes in Bitbake 1.9.x:
 	- Correctly add a task override in the form task-TASKNAME.
 	- Revert the '-' character fix in class names since it breaks things
 	- When a regexp fails to compile for PACKAGES_DYNAMIC, print a more useful error (#4444)
+	- Allow to checkout CVS by Date and Time. Just add HHmm to the SRCDATE.
 
 Changes in Bitbake 1.8.0:
 	- Release 1.7.x as a stable series

+ 5 - 1
lib/bb/fetch/cvs.py

@@ -118,7 +118,11 @@ class Cvs(Fetch):
         if 'norecurse' in ud.parm:
             options.append("-l")
         if ud.date:
-            options.append("-D \"%s UTC\"" % ud.date)
+            # treat YYYYMMDDHHMM specially for CVS
+            if len(ud.date) == 12:
+                options.append("-D \"%s %s:%s UTC\"" % (ud.date[0:8], ud.date[8:10], ud.date[10:12]))
+            else:
+                options.append("-D \"%s UTC\"" % ud.date)
         if ud.tag:
             options.append("-r %s" % ud.tag)