goappimage

package module
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Nov 7, 2020 License: MIT Imports: 4 Imported by: 0

README

GoAppImage

AppImage manipulation from Go. v0.2.0 and below are based on go-appimage. v0.3.0 and above use a staticly linked libappimage.

Calls fairly directly to AppImage C Library. Created for LinuxPA

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AppImage

type AppImage struct {
	//InternalFiles is a slice containing the names of ALL the AppImage's files. Backed by a C array.
	InternalFiles []string
	// contains filtered or unexported fields
}

AppImage is the representation of an AppImage. You must call Free() once your done to manually free up the C variables. It's recommended to defer Free() immediately after declaring so you don't forget.

func NewAppImage

func NewAppImage(location string) AppImage

NewAppImage creates a new AppImage tied to location.

func (*AppImage) ExtractDesktop added in v0.3.0

func (a *AppImage) ExtractDesktop(extractLocation string)

ExtractDesktop extracts the desktop file to extractLocation. Requires initialization.

func (*AppImage) ExtractFile

func (a *AppImage) ExtractFile(location, extractLocation string)

ExtractFile extracts the file at location to extractLocation. File should be found in AppImage.InternalFiles.

func (*AppImage) Free added in v0.3.0

func (a *AppImage) Free()

Free manually frees memory alocated to AppImage's C variables.

func (*AppImage) Initialize added in v0.3.0

func (a *AppImage) Initialize()

Initialize is a long process that allows some AppImage functions to work. Takes a long time.

func (*AppImage) Md5

func (a *AppImage) Md5() string

Md5 returns the md5 hash of the appimage

Jump to

Keyboard shortcuts

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