scp: return better error messages

Fixes #171
This commit is contained in:
Nicola Murino
2020-09-18 19:13:09 +02:00
parent 242dde4480
commit 209badf10c
5 changed files with 59 additions and 18 deletions

View File

@@ -40,6 +40,8 @@ type Fs interface {
ResolvePath(sftpPath string) (string, error)
IsNotExist(err error) bool
IsPermission(err error) bool
GetPermissionError() error
GetNotExistError() error
ScanRootDirContents() (int, int64, error)
GetDirSize(dirname string) (int, int64, error)
GetAtomicUploadPath(name string) string