all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Gregory Heytings <gregory@heytings.org>
Cc: mvar.40k@gmail.com, larsi@gnus.org, mcenturion@fing.edu.uy,
	arthur.miller@live.com, 47058@debbugs.gnu.org
Subject: bug#47058: 28.0.50; Dired Z: insert-directory: Reading directory: No such file or directory, CrossLine_linux_x86
Date: Wed, 22 Sep 2021 08:40:30 +0300	[thread overview]
Message-ID: <831r5hxj5d.fsf@gnu.org> (raw)
In-Reply-To: <052fb8a67e886712c3e6@heytings.org> (message from Gregory Heytings on Tue, 21 Sep 2021 19:19:52 +0000)

> Date: Tue, 21 Sep 2021 19:19:52 +0000
> From: Gregory Heytings <gregory@heytings.org>
> cc: mvar.40k@gmail.com, larsi@gnus.org, mcenturion@fing.edu.uy, 
>     arthur.miller@live.com, 47058@debbugs.gnu.org
> 
> >> TMP=$(mktemp -d ./XXXXXXXX)
> >> tar -C $TMP -x -z -f $FILE
> >> if (($(ls $TMP | wc -l) == 1))
> >> then
> >>    mv $TMP/* .
> >>    rmdir $TMP
> >> else
> >>    mv $TMP $(basename $FILE .tar.gz)
> >> fi
> >
> > Wouldn't that remove the files that are in the directory but not in the 
> > archive?
> 
> No, it does what I explained above:

If you move a directory over another by renaming, the previous
directory is gone, and replaced by the one you moved in its place,
right?  I'm not talking about what GNU mv does, I'm talking about what
Emacs will do when renaming a directory into another one.

> If all files in the tar file are under one directory (e.g. 
> emacs-27.2.tar.gz whose files are all in a emacs-27.2 directory), the 
> files will be in that directory.
> 
> If on the contrary the tar file is "broken" and its files are under 
> multiple directories or not in a directory (say foobar.tar.gz with three 
> files "/foo", "/bar" and "/baz"), the files will be put in a directory 
> "foobar".

That was not my question.





  parent reply	other threads:[~2021-09-22  5:40 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-10 20:26 bug#47058: 28.0.50; Dired Z: insert-directory: Reading directory: No such file or directory, CrossLine_linux_x86 Jean Louis
2021-08-31 21:33 ` Marco Centurion
2021-08-31 22:12   ` Arthur Miller
2021-09-01 13:59     ` Marco Centurion - URI
2021-09-01 16:06       ` Arthur Miller
2021-09-20 22:12       ` Michalis V.
2021-09-21  4:32         ` Lars Ingebrigtsen
2021-09-21  8:24           ` Eli Zaretskii
2021-09-21  9:18             ` Michalis V.
2021-09-21  9:32               ` Eli Zaretskii
2021-09-21 17:10                 ` Lars Ingebrigtsen
     [not found]                   ` <83a6k5yfrb.fsf@gnu.org>
2021-09-21 17:58                     ` Lars Ingebrigtsen
2021-09-21 18:38                   ` Gregory Heytings
2021-09-21 18:43                     ` Eli Zaretskii
2021-09-21 19:19                       ` Gregory Heytings
2021-09-21 20:11                         ` Michalis V.
2021-09-21 20:48                         ` Gregory Heytings
2021-09-22  5:40                         ` Eli Zaretskii [this message]
2021-09-22  7:15                           ` Gregory Heytings
2021-09-22  7:54                             ` Eli Zaretskii
2021-09-22  8:07                               ` Gregory Heytings
2021-09-21 17:07             ` Lars Ingebrigtsen
2021-09-21 20:43               ` Michalis V.
2021-09-22  6:00                 ` Eli Zaretskii
2021-09-21  8:25         ` Michael Albinus
2021-09-21  9:24           ` Michalis V.
2021-09-21 12:06             ` Michael Albinus
2022-03-11  8:29               ` Michael Albinus

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=831r5hxj5d.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=47058@debbugs.gnu.org \
    --cc=arthur.miller@live.com \
    --cc=gregory@heytings.org \
    --cc=larsi@gnus.org \
    --cc=mcenturion@fing.edu.uy \
    --cc=mvar.40k@gmail.com \
    /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.