Documentation
¶
Index ¶
- Constants
- func CleanURL(urlIn string) (string, error)
- func DecryptFile(infile *os.File, outfile *os.File, keyCallback func(string) ([]byte, error)) error
- func InterfaceValueToString(iv interface{}, format string) string
- func PathExist(path string) bool
- func ReadString(file *os.File, maxLen int) (string, error)
- type APIDestinationEntries
- type APIDestinationEntry
- type APIFileListEntries
- type APIFileListEntry
- type APIFileStatus
- type APIKeyListEntries
- type APIKeyListEntry
- type APIProjectInfos
- type APIProjectListEntries
- type APIProjectListEntry
- type APIPushStatus
- type APIStatus
Constants ¶
const ( APIFileStatusAvailable = "available" APIFileStatusRetrieving = "retrieving" APIFileStatusUnsealing = "unsealing" )
File status (for download)
const ( APIPushStatusPushing = "pushing" APIPushStatusSuccess = "success" APIPushStatusError = "error" )
Pusher status (for download)
const BarrySignature = "BARRY1"
const ClientVersion = "1.10.1"
ClientVersion of the client (x.y.z format)
const EncryptionIvSize = 16
const ProtocolVersion = 2
ProtocolVersion implemented
const ServerVersion = "0.22.1"
ServerVersion of the server
const TrueStr = "true"
TrueStr is the true truth.
Variables ¶
This section is empty.
Functions ¶
func DecryptFile ¶
DecryptFile will decrypt a file, where you must provide a callback to return the key
func InterfaceValueToString ¶
InterfaceValueToString converts most interface types to string
Types ¶
type APIDestinationEntries ¶
type APIDestinationEntries []APIDestinationEntry
APIDestinationEntries is a list of entries for "get destinations" command
type APIDestinationEntry ¶
APIDestinationEntry is an entry for a destination
type APIFileListEntries ¶
type APIFileListEntries []APIFileListEntry
APIFileListEntries is a list of file entries
type APIFileListEntry ¶
type APIFileListEntry struct { Filename string ModTime time.Time Size int64 ExpireLocal time.Time // expiration date ExpireRemote time.Time // (same) RemoteKeep time.Duration ExpiredLocal bool ExpiredRemote bool Container string Retrieved bool Encrypted bool }
APIFileListEntry is a file entry
type APIFileStatus ¶
APIFileStatus is the status of a file from barryd PoV
type APIKeyListEntries ¶
type APIKeyListEntries []APIKeyListEntry
APIKeyListEntries is a list of entries for "backup list" command
type APIKeyListEntry ¶
type APIKeyListEntry struct {
Comment string
}
APIKeyListEntry is an entry for a backup
type APIProjectInfos ¶
type APIProjectInfos struct { FileCountCurrent int SizeCountCurrent int64 `format:"size"` CostCurrent float64 `format:"money"` Archived bool BackupEvery time.Duration NewestModTime time.Time FinalExpiration time.Time LocalExpirationStr string RemoteExpirationStr string }
APIProjectInfos contains informations about a project
type APIProjectListEntries ¶
type APIProjectListEntries []APIProjectListEntry
APIProjectListEntries is a list of project entries
type APIProjectListEntry ¶
type APIProjectListEntry struct { Path string FileCountCurrent int SizeCountCurrent int64 CostCurrent float64 Archived bool }
APIProjectListEntry is a project entry
type APIPushStatus ¶
APIPushStatus is the status of a pusher
type APIStatus ¶
type APIStatus struct { Version string StartTime time.Time ProjectCount int FileCount int TotalFileSize int64 `format:"size"` TotalFileCost float64 `format:"money"` UploadQueueSize int EncryptQueueSize int Uploaders []string `format:"ignore"` Encrypters []string `format:"ignore"` }
APIStatus describes server status