Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

std/archive/tar.ts>Tar#append

Deno standard library
Go to Latest
The Standard Library has been moved to JSR. See the blog post for details.
method Tar.prototype.append
import { Tar } from "https://deno.land/std@0.218.0/archive/tar.ts";

Append a file or reader of arbitrary content to this tar archive. Directories appended to the archive append only the directory itself to the archive, not its contents. To add a directory and its contents, recursively append the directory's contents. Directories and subdirectories will be created automatically in the archive as required.

Parameters

filenameInArchive: string

file name of the content in the archive e.g., test.txt; use slash for directory separators

source: TarOptions

details of the source of the content including the reference to the content itself and potentially any related metadata.