How to untar in Emacs dired?

7

3

Is there a simple way to untar files in Emacs Dired? Currently I'm doing a M-! tar -xvf <filename>, however I feel like there is be an easier way.

loudandclear

Posted 2012-04-28T18:29:10.557

Reputation: 897

Answers

6

If you use dired extensively you should take a look at Dired Extra (it comes with Emacs), it has a feature that allows Emacs to guess what to do with files, e.g. just press ! with the archive selected and the prompt will suggest tar xvf, so a simple Return will do the job.

Just add this snippet to your ~/.emacs to load dired-x together with dired:

(add-hook 'dired-load-hook (function (lambda () (load "dired-x"))))

cYrus

Posted 2012-04-28T18:29:10.557

Reputation: 18 102

2

Check this EmacsWiki page, it points towards a dired-tar package that should do what you want: http://www.emacswiki.org/emacs/DiredPower#toc4

Anon

Posted 2012-04-28T18:29:10.557

Reputation: 21