assets

package
v1.9.5 Latest Latest
Warning

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

Go to latest
Published: Dec 5, 2022 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Overview

Package assets handles the site resources such as file downloads, thumbnails and backups.

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrStructNil = errors.New("structure cannot be nil")
	ErrPathEmpty = errors.New("path cannot be empty")
	ErrTarget    = errors.New("unknown target")
)

Functions

func Clean

func Clean(dir string, remove, human bool) error

Clean walks through and scans directories containing UUID files and erases any orphans that cannot be matched to the database.

func Cleaner added in v1.6.0

func Cleaner(t Target, d *directories.Dir, remove, human bool) error

func CreateUUIDMap

func CreateUUIDMap() (total int, uuids database.IDs, err error)

CreateUUIDMap builds a map of all the unique UUID values stored in the Defacto2 database.

func Targets added in v1.6.0

func Targets(t Target, d *directories.Dir) []string

Types

type Target

type Target int

Target filters the file assets.

const (
	All       Target = iota // All files.
	Download                // Download are files for download.
	Emulation               // Emulation are files for the DOSee emulation.
	Image                   // Image and thumbnail files.
)

Directories

Path Synopsis
internal

Jump to

Keyboard shortcuts

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