FANDOM


Use this page to discuss script 1970 deb: browse debian package

  • Add constructive comments, bug reports, or discuss improvements (see the guideline).
  • Do not document the script here (the author should do that on vim.org).
  • This page may be out of date: check the script's vim.org page above, and its release notes.

data.tar.xz fixEdit

Version 1.4 of deb.vim cannot read files inside a Debian package that names its data file "data.tar.xz". The following patch fixes this behavior:

 diff -Naur deb-orig/autoload/deb.vim deb-fixed/autoload/deb.vim
 --- deb-orig/autoload/deb.vim	2008-04-01 22:06:57.000000000 +0000
 +++ deb-fixed/autoload/deb.vim	2017-07-29 03:50:47.207512935 +0000
 @@ -37,6 +37,8 @@
              return
          endif
          let l:unpcmp = "lzma -d | tar xfO "
 +    elseif l:archmember == "data.tar.xz"
 +        let l:unpcmp = "tar JxfO "
      elseif l:archmember == "data.tar"
          let l:unpcmp = "tar xfO "
      endif
 @@ -228,9 +230,9 @@
  endfun
  
  " return data file name for debian package. This can be either data.tar.gz,
 -" data.tar.bz2 or data.tar.lzma
 +" data.tar.bz2, data.tar.lzma, data.tar.xz, or data.tar.
  fun s:dataFileName(deb)
 -    for fn in ["data.tar.gz", "data.tar.bz2", "data.tar.lzma", "data.tar"]
 +    for fn in ["data.tar.gz", "data.tar.bz2", "data.tar.lzma", "data.tar.xz", "data.tar"]
          " [0:-2] is to remove trailing null character from command output
          if (system("ar t " . "'" . a:deb . "'" . " " . fn))[0:-2] == fn
              return fn

--‎Jwodder, July 29, 2017

CommentsEdit

Ad blocker interference detected!


Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.