ZyX_I avatar ZyX_I committed acf1a77

doc: Fixed docs for rf-annotate()
@aurum/drivers/mercurial: Made line numbers be always numbers, not strings, and revisions be always strings, not numbers

Comments (0)

Files changed (3)

     Check whether file is “dirty” (meaning that it has changes that can be 
     committed).
   annotate :: repo, hex, file -> [ rev ]                   *aurum-rf-annotate*
-    Returns a list of revision numbers: one revision number for each line of 
-    the file as it was at given changeset.
+    Returns a list of 3-tuples: ({hex}, {file}, {line-number}), one 3-tuple 
+    for each line of the file as it was at given changeset. {hex} must be 
+    anything supported by |aurum-rf-getcs|, {file} is a filename (in case this 
+    function is able to track copies or renames) and {line-number} is number 
+    of the corresponding line in that file as it was at that revision.
   diff :: hex, hex, [ file ], diffopts -> [ String ]           *aurum-rf-diff*
     Returns list of strings (similar to |readfile()| output with "b" flag set) 
     that contains changes made to given files between given revisions. If list 

plugin/aurum/drivers/mercurial.vim

         if empty(match)
             call s:_f.throw('annfail', a:rev, a:file, line)
         endif
-        let r+=[[match[2], str2nr(match[1]), str2nr(match[3])]]
+        let r+=[[match[2], match[1], str2nr(match[3])]]
     endfor
     return r
 endfunction
     try:
         ann=g_fctx(g_cs(g_repo(path), rev), filepath).annotate(follow=True,
                                                                linenumber=True)
-        ann_vim=[(line[0][0].path(), str(line[0][0].rev()), str(line[0][1]))
+        ann_vim=[(line[0][0].path(), str(line[0][0].rev()), line[0][1])
                                                                 for line in ann]
         vim.eval('extend(r, '+nonutf_dumps(ann_vim)+')')
     except AurumError:
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 ProjectModifiedEvent.java.
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.