patch-ranger_data_scope_sh 1006 B

1234567891011121314151617181920212223
  1. $OpenBSD: patch-ranger_data_scope_sh,v 1.3 2015/11/19 19:13:35 jasper Exp $
  2. Meant to use atool (not ported yet), but bsdtar copes with many of these
  3. archives directly so use that instead.
  4. --- ranger/data/scope.sh.orig Sun Oct 4 01:46:45 2015
  5. +++ ranger/data/scope.sh Thu Nov 19 20:09:03 2015
  6. @@ -1,4 +1,4 @@
  7. -#!/usr/bin/env sh
  8. +#!/bin/ksh
  9. # ranger supports enhanced previews. If the option "use_preview_script"
  10. # is set to True and this file exists, this script will be called and its
  11. # output is displayed in ranger. ANSI color codes are supported.
  12. @@ -48,7 +48,7 @@ case "$extension" in
  13. # Archive extensions:
  14. 7z|a|ace|alz|arc|arj|bz|bz2|cab|cpio|deb|gz|jar|lha|lz|lzh|lzma|lzo|\
  15. rpm|rz|t7z|tar|tbz|tbz2|tgz|tlz|txz|tZ|tzo|war|xpi|xz|Z|zip)
  16. - try als "$path" && { dump | trim; exit 0; }
  17. + try bsdtar "$path" && { dump | trim; exit 0; }
  18. try acat "$path" && { dump | trim; exit 3; }
  19. try bsdtar -lf "$path" && { dump | trim; exit 0; }
  20. exit 1;;