Page 1 of 1

Feature request - update/improve a TAR module. And ZSTD unpacking support.

Posted: 2023-03-30, 07:06 UTC
by lelik007
Hello Christian! I'd like to ask you for updating/improving a TAR module.
TC now creates Gnu Tar archives with my Windows code page (1251). And I'm not sure of what name length.
Most recent Gnu Tar format if you so choose may have Unicode for the file names and have unlimited file names and file sizes.

What actually I'm asking for:
Or/and - update a Gnu Tar format to the latest version available and make a switch - like we have for the internal Zip
packer now - what encoding to use for the file names. I just mean to make somewhat customizable Tar format.
The second idea is to leave Gnu Tar format as is and implement POSIX.1-2001/pax format (it has Unicode file names by default) as the most recent and advanced format available for TAR now. And make a switch for it.
---
And the third idea is about Z-standard. In past few years it's become widely used for Linux and cross-platform software (manuals, sources, packages)
I'd like to ask for a native support to unpack zst, tar.zst, tzst files. I know it's not very easy now to do because we don't have separate .dll just for unpacking (like 7zxa.dll or unrar.dll). But I'd like to ask Yann Collett (the author of ZSTD format) to create this .dll. Maybe he'll agree so you could implement it in the future releases. I don't know is it difficult to do or not to split libzstd.dll in parts and include just the part that decompresses.

Re: Feature request - update/improve a TAR module.

Posted: 2023-03-30, 08:58 UTC
by white

Moderator message from: white ยป 2023-03-30, 08:57 UTC

Moved to Suggestions forum.

Re: Feature request - update/improve a TAR module. And ZSTD unpacking support.

Posted: 2023-03-30, 17:42 UTC
by nice
7zip with zstd support: https://github.com/mcmilk/7-Zip-zstd
they suggest replacing total commander dlls, but I would be better replacing the libraries in total7zip

Re: Feature request - update/improve a TAR module. And ZSTD unpacking support.

Posted: 2023-03-31, 04:31 UTC
by lelik007
nice wrote: โ†‘2023-03-30, 17:42 UTC 7zip with zstd support: https://github.com/mcmilk/7-Zip-zstd
they suggest replacing total commander dlls, but I would be better replacing the libraries in total7zip
I personally prefer this ZSTD solution https://www.tc4shell.com/en/7zip/modern7z/ for
Total7zip. This does the job... but I'd like to have native unpacking capabilities in TC.

But it's kinda tricky - Yann Collet (author of ZSTD) doesn't provide decompressing only .dll
just full-featured libzstd.dll (for both compression and decompression) - it's 1.16 Mb and too
heavy for TC. I don't know If Christian could separate decompressing part and make a special .dll
for TC.

Re: Feature request - update/improve a TAR module. And ZSTD unpacking support.

Posted: 2023-03-31, 13:57 UTC
by Dalai
Although it's not native, i.e. built-in, but there is a zstd packer plugin for TC: https://totalcmd.net/plugring/zstdwcx.html

Regards
Dalai

Re: Feature request - update/improve a TAR module. And ZSTD unpacking support.

Posted: 2023-03-31, 14:08 UTC
by ghisler(Author)
TC now creates Gnu Tar archives with my Windows code page (1251). And I'm not sure of what name length.
Most recent Gnu Tar format if you so choose may have Unicode for the file names and have unlimited file names and file sizes.
Unfortunately it doesn't seem to set any flag to determine whether a name is using ANSI or UTF-8. There have been problems with Asian languages where a sequence of bytes can be both a valid ANSI and UTF-8 name.

Regarding zstd, the next version of Total Commander will have a native unpacker included.

Re: Feature request - update/improve a TAR module. And ZSTD unpacking support.

Posted: 2023-04-01, 11:21 UTC
by lelik007
ghisler(Author) wrote: โ†‘2023-03-31, 14:08 UTC Unfortunately it doesn't seem to set any flag to determine whether a name is using ANSI or UTF-8. There have been problems with Asian languages where a sequence of bytes can be both a valid ANSI and UTF-8 name.
Regarding zstd, the next version of Total Commander will have a native unpacker included.
Thanks a lot for ZSTD decompression. It'll be nice to have it.
About TAR - In Windows 10/11 now there's bsdtar included but really old version. It's from https://github.com/libarchive/libarchive
bsdtar creates POSIX.1-2001/pax TAR with unicode names by default. I believe it's defined in standard. That's why I asked for this format.
But for Gnu Tar (format) there's an option: so it would be like tar cfv "foo.tar" --format gnutar --options="hdrcharset=utf-8" "foo.txt"
Because without this options different tar implementations do what they want - either use a system code page like cp1251 or even a console
code page like cp866. But I'm not really sure how it's defined in output Gnu Tar format file...

Re: Feature request - update/improve a TAR module. And ZSTD unpacking support.

Posted: 2023-04-04, 10:35 UTC
by ghisler(Author)
To my knowledge, TAR uses the current default system encoding of the PC where you run it. It doesn't store anywhere what encoding it used.

I have just tested bsdtar, it indeed creates UTF-8 names, and TC shows them correctly.

Re: Feature request - update/improve a TAR module. And ZSTD unpacking support.

Posted: 2023-04-06, 08:49 UTC
by lelik007
ghisler(Author) wrote: โ†‘2023-04-04, 10:35 UTC To my knowledge, TAR uses the current default system encoding of the PC where you run it. It doesn't store anywhere what encoding it used.

I have just tested bsdtar, it indeed creates UTF-8 names, and TC shows them correctly.
You are very right because it's bsdtar program uses POSIX.1-2001/pax by default and it's unicode only.
Not Gnu tar implemented in TC now. So that's why I'm asking for it. So at some point I'd not have this.

[IMG]https://cdn-thumbs.imagevenue.com/e9/d5/bf/ME167OXO_t.jpg[/IMG]
It's not my system code page it's console code page.