summaryrefslogtreecommitdiff
path: root/Userland/Utilities/tar.cpp
AgeCommit message (Collapse)Author
2023-02-13Everywhere: Remove the `AK::` qualifier from Stream usagesTim Schumacher
2023-02-13LibCore: Remove `Stream.h`Tim Schumacher
2023-02-13LibCore: Move Stream-based file into the `Core` namespaceTim Schumacher
2023-02-13LibCore: Rename `File` to `DeprecatedFile`Tim Schumacher
As usual, this removes many unused includes and moves used includes further down the chain.
2023-02-10Everywhere: Remove needless copies of Error / ErrorOr instancesTimothy Flynn
Either take the underlying objects with release_* methods or move() the instances around.
2023-01-29AK: Move `Stream` and `SeekableStream` from `LibCore`Tim Schumacher
`Stream` will be qualified as `AK::Stream` until we remove the `Core::Stream` namespace. `IODevice` now reuses the `SeekMode` that is defined by `SeekableStream`, since defining its own would require us to qualify it with `AK::SeekMode` everywhere.
2023-01-20LibCore: Remove `FileStream`Tim Schumacher
2023-01-10LibCompress: Port `GzipCompressor` to `Core::Stream`Tim Schumacher
2023-01-08LibArchive+Utilities: Stop using DeprecatedStringimplicitfield
This also slightly improves error propagation in tar, unzip and zip.
2023-01-02Everywhere: Fix badly-formatted includesBen Wiederhake
In 7c5e30daaa615ad3a2ef55222423a747ac0a1227, the focus was "only" on Userland/Libraries/, whereas this commit cleans up the remaining headers in the repo, and any new badly-formatted include.
2022-12-14LibArchive: Do some error propagation while packing tar filesTim Schumacher
2022-12-14LibArchive: Port `TarOutputStream` to `Core::Stream`Tim Schumacher
2022-12-10LibCompress: Port GzipDecompressor to `Core::Stream`Tim Schumacher
2022-12-06Everywhere: Rename to_{string => deprecated_string}() where applicableLinus Groh
This will make it easier to support both string types at the same time while we convert code, and tracking down remaining uses. One big exception is Value::to_string() in LibJS, where the name is dictated by the ToString AO.
2022-12-06AK+Everywhere: Rename String to DeprecatedStringLinus Groh
We have a new, improved string type coming up in AK (OOM aware, no null state), and while it's going to use UTF-8, the name UTF8String is a mouthful - so let's free up the String name by renaming the existing class. Making the old one have an annoying name will hopefully also help with quick adoption :^)
2022-11-30LibArchive: Move loading the next tar header into a helper functionTim Schumacher
This now also validates the first header that is loaded, so we can drop the corresponding FIXME from `tar`.
2022-11-30LibArchive: Use Core::Stream inside `TarInputStream`Tim Schumacher
2022-11-30LibArchive: Port `TarFileStream` to `Core::Stream`Tim Schumacher
2022-11-26FuzzTar+tar: Advance the stream before continuingimplicitfield
Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=53733 This bug was caused by a regression introduced in c88d8a2.
2022-11-23LibArchive: Simplify error handlingimplicitfield
2022-11-13LibArchive: Make get_field_as_integral error out on non-octal inputimplicitfield
Fixes this bug that was reported by OSS-Fuzz: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=52493
2022-11-13LibArchive: Make TarInputStream::advance report errorsimplicitfield
Fixes this bug that was reported by OSS-Fuzz: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=52862
2022-10-31Utilities+LibArchive: Don't follow symlinksPeter Elliott
2022-07-12Userland: Convert command line arguments to String/StringViewsin-ack
StringView was used where possible. Some utilities still use libc functions which expect null-terminated strings, so String objects were used there instead.
2022-06-06tar: Implement support for GNU longname headersTim Schumacher
2022-04-11Utilities: Read positional arguments as Strings not char*sSam Atkins
This is a pretty trivial change so they're all batched together.
2022-04-11LibCore+Userland: Remove File::ensure_parent_directorieskleines Filmröllchen
We have a much safer and more powerful alternative now, so let's move the few users over.
2022-04-01Everywhere: Run clang-formatIdan Horowitz
2022-03-05tar: Implement support for extended headers :^)Tim Schumacher
2022-03-05tar: Use the prefixed path for listing and verbose outputTim Schumacher
2022-03-05tar: Prevent file buffering from reading uninitialized dataTim Schumacher
Regressed in 91fa10a0ab6bdb48e0f98d225bf87d77dcbce027.
2022-03-02Utilities: Port tar to LibMaincocateh
Ported tar to LibMain and changed it to use Core::System syscalls.
2022-02-18tar: Automatically recognize gzip archivesTim Schumacher
2022-01-04tar: Implement -C optioncircl
This allows specifying which directory to extract to or create from. I would have used the *at variants of the functions, but some weren't implemented yet.
2021-11-22tar: Support extracting symlinksTim Schumacher
We can now extract GitHub's LLVM tarballs. :^)
2021-11-22tar: Implement usage of prefixes when extractingTim Schumacher
2021-11-13Utilities/tar: Ignore directory entry if it already existsTim Schumacher
2021-11-10Utilities: tar: Always create parent directory when extractingTim Schumacher
2021-09-01Everywhere: Use my cool new @serenityos.org email addressPeter Elliott
2021-05-24tar: Ignore "extended headers"Lynn
Looking around online, it seems like this is normally a bit of metadata that the extract operation can safely ignore.
2021-05-17Utilities: Correct non-standard assert macros includesJean-Baptiste Boric
2021-05-12LibCore+Everywhere: Move OpenMode out of IODeviceAli Mohammad Pur
...and make it an enum class so people don't omit "OpenMode".
2021-04-29Everywhere: "file name" => "filename"Andreas Kling
2021-04-29Utilities: Use Vector<String> positional arguments in some placesAndreas Kling
There are more places we can use these, I just picked some that felt like they improved the code.
2021-04-29Userland: Fix new GCC warningsGunnar Beutner
2021-04-22Everything: Move to SPDX license identifiers in all files.Brian Gianforcaro
SPDX License Identifiers are a more compact / standardized way of representing file license information. See: https://spdx.dev/resources/use/#identifiers This was done with the `ambr` search and replace tool. ambr --no-parent-ignore --key-from-file --rep-from-file key.txt rep.txt *
2021-03-23Libraries: Rename LibTar to LibArchiveIdan Horowitz
This is in preparation for a new implementation of zip archive extraction and creation.
2021-03-13tar: Implement tar archive creationIdan Horowitz
This completes our tar utility by implementing the -c option for archive creation using TarOutputStream and optionally GzipCompressor for compression via the -z option.
2021-03-13LibTar: Implement TarOutputStreamIdan Horowitz
This output stream creates gnu format tar archives and currently only supports files and directories.
2021-03-12Everywhere: Remove klog(), dbg() and purge all LogStream usage :^)Andreas Kling
Good-bye LogStream. Long live AK::Format!