Documentation ¶
Overview ¶
archive features for goxc. Limited support for zip, tar.gz and ar archiving
Index ¶
- func ArchiveBinariesAndResources(outDir, platName string, binPaths []string, appName string, resources []string, ...) (zipFilename string, err error)
- func TarGz(archiveFilename string, itemsToArchive []ArchiveItem) error
- func TarGzWrite(item ArchiveItem, tw *tar.Writer, fi os.FileInfo) (err error)
- func Zip(zipFilename string, itemsToArchive []ArchiveItem) error
- type ArchiveItem
- type Archiver
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ArchiveBinariesAndResources ¶
func ArchiveBinariesAndResources(outDir, platName string, binPaths []string, appName string, resources []string, settings config.Settings, archiver Archiver, ending string, includeTopLevelDir bool) (zipFilename string, err error)
goxc function to archive a binary along with supporting files (e.g. README or LICENCE).
func TarGz ¶
func TarGz(archiveFilename string, itemsToArchive []ArchiveItem) error
TarGz implementation of Archiver.
func TarGzWrite ¶
Write a single file to TarGz
Types ¶
type ArchiveItem ¶
type ArchiveItem struct { //if FileSystemPath is empty, use Data instead FileSystemPath string ArchivePath string Data []byte }
type definition representing a file to be archived. Details location on filesystem and destination filename inside archive.
func ArchiveItemFromBytes ¶
func ArchiveItemFromBytes(data []byte, archivePath string) ArchiveItem
func ArchiveItemFromFileSystem ¶
func ArchiveItemFromFileSystem(fileSystemPath, archivePath string) ArchiveItem
type Archiver ¶
type Archiver func(archiveFilename string, itemsToArchive []ArchiveItem) error
type definition for different archiving implementations
Click to show internal directories.
Click to hide internal directories.