archive

package
v1.1.0-beta.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 23, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package archive provides small filesystem zip/unzip helpers with no dependency on any application domain package.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RemoveAllInDirExcept

func RemoveAllInDirExcept(dir string, exclude map[string]struct{}) error

RemoveAllInDirExcept deletes every entry under dir except the absolute paths listed in exclude.

func UnzipToDir

func UnzipToDir(zipPath, dstDir string) error

UnzipToDir extracts zipPath into dstDir, guarding against path traversal.

func ZipDirectoryExcluding

func ZipDirectoryExcluding(srcDir, dstZip string, exclude map[string]struct{}) error

ZipDirectoryExcluding packs srcDir into dstZip. exclude is a set of absolute paths to skip.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL