all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Noam Postavsky <npostavs@users.sourceforge.net>
To: Max <mu@magi.net.ru>
Cc: 29094@debbugs.gnu.org
Subject: bug#29094: dired-do-compress creates empty archives
Date: Mon, 04 Dec 2017 20:46:07 -0500	[thread overview]
Message-ID: <87bmjegd5s.fsf@users.sourceforge.net> (raw)
In-Reply-To: <20171031233359.GA44370@magi.net.ru> (Max's message of "Wed, 1 Nov 2017 02:33:59 +0300")

tags 29094 + patch
quit

Max <mu@magi.net.ru> writes:

> When Z is pressed on a directory, dired (according to
> dired-compress-file-suffixes variable) runs the following command:
>
> tar -c directory | gzip -c9 > directory.tar.gz
>
> On my system running this command results in an error:
>
> tar: Failed open to write on /dev/rst0: Permission denied
>
> as tar(1) defaults -f to /dev/rst0.
>
> Argument '-f-' should be used to write to stdout.

Right, the GNU tar manual says [1]

    By default, tar uses an archive file name that was compiled when it was
    built on the system; usually this name refers to some physical tape
    drive on the machine. However, the person who installed tar on the
    system may not have set the default to a meaningful value as far as most
    users are concerned.

So it's actually a bit surprising that the current values apparently
work for most people.  I guess most GNU/Linux distros set the default to
stdin?

As far as I can tell, dropping the 'f' option was just an oversight (see
[2] and other messages in that thread).

> Also '-v' is probably not needed here, since the output is not used
> anywhere.

Makes sense.

> Here is a patch to correct this behaviour:

I think it's good for emacs-26.  I assume you haven't assigned copyright
to Emacs (so it should be marked as a tiny change)?

[1]: https://www.gnu.org/software/tar/manual/html_node/file.html
[2]: https://lists.gnu.org/archive/html/emacs-devel/2015-10/msg01282.html 





  reply	other threads:[~2017-12-05  1:46 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-31 23:33 bug#29094: dired-do-compress creates empty archives Max
2017-12-05  1:46 ` Noam Postavsky [this message]
2017-12-07  3:25   ` Max
2017-12-08  9:53     ` Eli Zaretskii
2017-12-08  9:51   ` Eli Zaretskii
2017-12-11 23:48     ` Noam Postavsky

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87bmjegd5s.fsf@users.sourceforge.net \
    --to=npostavs@users.sourceforge.net \
    --cc=29094@debbugs.gnu.org \
    --cc=mu@magi.net.ru \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.