aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJuri Linkov2011-07-08 03:08:53 +0300
committerJuri Linkov2011-07-08 03:08:53 +0300
commitcd79ce90d966b292c2893a6e5f7f13b5c84477ce (patch)
tree4cecd7fa41861f0d27fa0dcd3efdc86cf4a19528
parent72aba33f59d0ba30a01adf7aa7952b5839a8410d (diff)
downloademacs-cd79ce90d966b292c2893a6e5f7f13b5c84477ce.tar.gz
emacs-cd79ce90d966b292c2893a6e5f7f13b5c84477ce.zip
* lisp/arc-mode.el (archive-zip-expunge, archive-zip-update)
(archive-zip-update-case): Use 7z if found by `executable-find'. The order of searching the available programs is the same as in `archive-zip-extract'. Fixes: debbugs:8968
-rw-r--r--lisp/ChangeLog7
-rw-r--r--lisp/arc-mode.el48
2 files changed, 31 insertions, 24 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index f9c55aad1b3..74b36f4ab05 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,10 @@
12011-07-08 Juri Linkov <juri@jurta.org>
2
3 * arc-mode.el (archive-zip-expunge, archive-zip-update)
4 (archive-zip-update-case): Use 7z if found by `executable-find'.
5 The order of searching the available programs is the same as in
6 `archive-zip-extract' (bug#8968).
7
12011-07-07 Chong Yidong <cyd@stupidchicken.com> 82011-07-07 Chong Yidong <cyd@stupidchicken.com>
2 9
3 * menu-bar.el (menu-bar-line-wrapping-menu): Revert last change. 10 * menu-bar.el (menu-bar-line-wrapping-menu): Revert last change.
diff --git a/lisp/arc-mode.el b/lisp/arc-mode.el
index 70f43aebaff..ea875b9989d 100644
--- a/lisp/arc-mode.el
+++ b/lisp/arc-mode.el
@@ -216,10 +216,10 @@ Archive and member name will be added."
216;; Zip archive configuration 216;; Zip archive configuration
217 217
218(defcustom archive-zip-extract 218(defcustom archive-zip-extract
219 (cond ((executable-find "unzip") '("unzip" "-qq" "-c")) 219 (cond ((executable-find "unzip") '("unzip" "-qq" "-c"))
220 ((executable-find "7z") '("7z" "x" "-so")) 220 ((executable-find "7z") '("7z" "x" "-so"))
221 ((executable-find "pkunzip") '("pkunzip" "-e" "-o-")) 221 ((executable-find "pkunzip") '("pkunzip" "-e" "-o-"))
222 (t '("unzip" "-qq" "-c"))) 222 (t '("unzip" "-qq" "-c")))
223 "Program and its options to run in order to extract a zip file member. 223 "Program and its options to run in order to extract a zip file member.
224Extraction should happen to standard output. Archive and member name will 224Extraction should happen to standard output. Archive and member name will
225be added." 225be added."
@@ -235,44 +235,44 @@ be added."
235;; names. 235;; names.
236 236
237(defcustom archive-zip-expunge 237(defcustom archive-zip-expunge
238 (if (and (not (executable-find "zip")) 238 (cond ((executable-find "zip") '("zip" "-d" "-q"))
239 (executable-find "pkzip")) 239 ((executable-find "7z") '("7z" "d"))
240 '("pkzip" "-d") 240 ((executable-find "pkzip") '("pkzip" "-d"))
241 '("zip" "-d" "-q")) 241 (t '("zip" "-d" "-q")))
242 "Program and its options to run in order to delete zip file members. 242 "Program and its options to run in order to delete zip file members.
243Archive and member names will be added." 243Archive and member names will be added."
244 :type '(list (string :tag "Program") 244 :type '(list (string :tag "Program")
245 (repeat :tag "Options" 245 (repeat :tag "Options"
246 :inline t 246 :inline t
247 (string :format "%v"))) 247 (string :format "%v")))
248 :group 'archive-zip) 248 :group 'archive-zip)
249 249
250(defcustom archive-zip-update 250(defcustom archive-zip-update
251 (if (and (not (executable-find "zip")) 251 (cond ((executable-find "zip") '("zip" "-q"))
252 (executable-find "pkzip")) 252 ((executable-find "7z") '("7z" "u"))
253 '("pkzip" "-u" "-P") 253 ((executable-find "pkzip") '("pkzip" "-u" "-P"))
254 '("zip" "-q")) 254 (t '("zip" "-q")))
255 "Program and its options to run in order to update a zip file member. 255 "Program and its options to run in order to update a zip file member.
256Options should ensure that specified directory will be put into the zip 256Options should ensure that specified directory will be put into the zip
257file. Archive and member name will be added." 257file. Archive and member name will be added."
258 :type '(list (string :tag "Program") 258 :type '(list (string :tag "Program")
259 (repeat :tag "Options" 259 (repeat :tag "Options"
260 :inline t 260 :inline t
261 (string :format "%v"))) 261 (string :format "%v")))
262 :group 'archive-zip) 262 :group 'archive-zip)
263 263
264(defcustom archive-zip-update-case 264(defcustom archive-zip-update-case
265 (if (and (not (executable-find "zip")) 265 (cond ((executable-find "zip") '("zip" "-q" "-k"))
266 (executable-find "pkzip")) 266 ((executable-find "7z") '("7z" "u"))
267 '("pkzip" "-u" "-P") 267 ((executable-find "pkzip") '("pkzip" "-u" "-P"))
268 '("zip" "-q" "-k")) 268 (t '("zip" "-q" "-k")))
269 "Program and its options to run in order to update a case fiddled zip member. 269 "Program and its options to run in order to update a case fiddled zip member.
270Options should ensure that specified directory will be put into the zip file. 270Options should ensure that specified directory will be put into the zip file.
271Archive and member name will be added." 271Archive and member name will be added."
272 :type '(list (string :tag "Program") 272 :type '(list (string :tag "Program")
273 (repeat :tag "Options" 273 (repeat :tag "Options"
274 :inline t 274 :inline t
275 (string :format "%v"))) 275 (string :format "%v")))
276 :group 'archive-zip) 276 :group 'archive-zip)
277 277
278(defcustom archive-zip-case-fiddle t 278(defcustom archive-zip-case-fiddle t