added sftp client implementation

This commit is contained in:
ston1th 2022-04-02 20:05:07 +02:00
commit ce73f0472c
175 changed files with 28135 additions and 13 deletions

View file

@ -18,8 +18,8 @@ type FS struct {
root string
}
func NewFS(root string) *FS {
return &FS{root}
func NewFS(root string) (*FS, error) {
return &FS{root}, nil
}
func (fs *FS) path(p string) string {
@ -55,3 +55,7 @@ func (fs *FS) Fstat(fd uintptr) (int64, error) {
err := unix.Fstat(int(fd), &stat)
return stat.Blocks, err
}
func (FS) Close() error {
return nil
}