bug-tar
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

'tar --delete' destroys an archive


From: Ingo Brückl
Subject: 'tar --delete' destroys an archive
Date: Mon, 18 Apr 2022 21:31:51 +0200

Get bash-5.1.16.tar.gz from https://ftp.gnu.org/gnu/bash/.

Gunzip it.

Extract the original: tar xf bash-5.1.16.tar && mv bash-5.1.16 bash-org.

Remove lib/glob from bash-org: rm -r bash-org/lib/glob.

Now delete lib/glob from the tar file using: tar --delete --no-recursion 
--no-wildcards -f 'bash-5.1.16.tar' -- 'bash-5.1.16/lib/glob/sm_loop.c' 
'bash-5.1.16/lib/glob/glob.h' 'bash-5.1.16/lib/glob/xmbsrtowcs.c' 
'bash-5.1.16/lib/glob/glob.c' 'bash-5.1.16/lib/glob/smatch.c' 
'bash-5.1.16/lib/glob/doc/glob.texi' 'bash-5.1.16/lib/glob/doc/Makefile' 
'bash-5.1.16/lib/glob/doc/' 'bash-5.1.16/lib/glob/gm_loop.c' 
'bash-5.1.16/lib/glob/Makefile.in' 'bash-5.1.16/lib/glob/gmisc.c' 
'bash-5.1.16/lib/glob/collsyms.h' 'bash-5.1.16/lib/glob/glob_loop.c' 
'bash-5.1.16/lib/glob/strmatch.c' 'bash-5.1.16/lib/glob/ndir.h' 
'bash-5.1.16/lib/glob/strmatch.h' 'bash-5.1.16/lib/glob/'.

Extract the changed tar file: tar xf bash-5.1.16.tar && mv bash-5.1.16 bash-del.

Now compare: diff -Nur bash-org bash-del.

You'll find lib/readline/doc/hstech.texi changed and 
lib/readline/doc/rluserman.texi deleted!

This happens with tar 1.30 (debian/buster) as well as with tar 1.34 
(self-compiled).



reply via email to

[Prev in Thread] Current Thread [Next in Thread]