ZyX_I committed e85c104

@aurum/drivers/subversion: Fixed rf-updatechangesets() and r2fst error message

Comments (0)

Files changed (1)


             \           'in the output of “svn info”',
             \  'ndate': 'You must install “date” programm in order to get '.
             \           'time information for Subversion revisions',
-            \  'r2fst': 'Second revision was found before the first',
+            \  'r2fst': 'Second revision (%s) was found before the first (%s)',
             \     'u3': 'Subversion supports only three lines '.
             \           'of unified context, you gave %u',
             \ 'iediff': 'Diff parser error: expected at least one more line '.
 "▶1 svn.updatechangesets :: repo → _
 function s:svn.updatechangesets(repo)
-    let oldtiphex=a:repo.cslist[-1].hex
-    let tiphex=a:repo.functions.gettiphex(a:repo)
-    if tiphex<oldtiphex
-        call remove(a:repo.cslist, +tiphex, -1)
-    elseif tiphex>oldtiphex
-        let cslist=s:F.getchangesets(a:repo, oldtiphex, tiphex)
+    let oldtiprev=a:repo.cslist[-1].rev
+    let tiprev=+a:repo.functions.gettiphex(a:repo)
+    if tiprev<oldtiprev
+        while !empty(a:repo.cslist) && a:repo.cslist[-1].rev>tiprev
+            call remove(a:repo.cslist, -1)
+        endwhile
+    elseif tiprev>oldtiprev
+        let cslist=s:F.getchangesets(a:repo, ''.oldtiprev, ''.tiprev)
         if !empty(cslist)
             let a:repo.cslist[-1].children=''.(a:repo.cslist[-1].rev+1)
             call map(cslist[:-2], 'extend(v:val, {"children": '.
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.