handlers

package
v0.0.0-...-9b09fdb Latest Latest
Warning

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

Go to latest
Published: May 8, 2022 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const (
	BACKUP_NO_CHANGE backupStatus = iota
	BACKUP_USER_CANCEL
	BACKUP_NO_ACTIONS
	BACKUP_SUCCESS
)
View Source
const (
	ENCRYPT_SKIP encryptStatus = iota
	ENCRYPT_CONTINUE
	ENCRYPT_USER_CANCEL
)
View Source
const (
	RESTORE_USER_CANCEL restoreStatus = iota
	RESTORE_NO_ACTIONS
	RESTORE_SUCCESS
)

Variables

This section is empty.

Functions

func HandleBackup

func HandleBackup(cfg *config.Config, flags BackupFlags) (backupStatus, error)

func HandleDecrypt

func HandleDecrypt(cfg *config.Config, dataPath string, noEncrypt bool) (encryptStatus, error)

func HandleEncrypt

func HandleEncrypt(cfg *config.Config, dataPath string, noEncrypt bool) (encryptStatus, error)

func HandleHash

func HandleHash(cfg *config.Config, dataPath string, skipCompare bool) (*hashResult, error)

func HandleRestore

func HandleRestore(cfg *config.Config, flags RestoreFlags) (restoreStatus, error)

Types

type BackupFlags

type BackupFlags struct {
	Only   []string
	Except []string

	Force     bool
	NoEncrypt bool
}

type HashStatus

type HashStatus int
const (
	HASH_NO_CHANGE HashStatus = iota
	HASH_CONTINUE
)

type RestoreFlags

type RestoreFlags struct {
	Only   []string
	Except []string

	Force     bool
	NoEncrypt bool
	NoBackup  bool

	Action string
	File   string
}

Jump to

Keyboard shortcuts

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