From 51062863a5c34d81e296cf15c61140911037cf3b Mon Sep 17 00:00:00 2001 From: Wim Date: Mon, 6 Aug 2018 21:47:05 +0200 Subject: Use mod vendor for vendored directory (backwards compatible) --- vendor/github.com/pkg/sftp/server_stubs.go | 32 ------------------------------ 1 file changed, 32 deletions(-) delete mode 100644 vendor/github.com/pkg/sftp/server_stubs.go (limited to 'vendor/github.com/pkg/sftp/server_stubs.go') diff --git a/vendor/github.com/pkg/sftp/server_stubs.go b/vendor/github.com/pkg/sftp/server_stubs.go deleted file mode 100644 index a14c7348..00000000 --- a/vendor/github.com/pkg/sftp/server_stubs.go +++ /dev/null @@ -1,32 +0,0 @@ -// +build !cgo,!plan9 windows android - -package sftp - -import ( - "os" - "time" - "fmt" -) - -func runLs(dirname string, dirent os.FileInfo) string { - typeword := runLsTypeWord(dirent) - numLinks := 1 - if dirent.IsDir() { - numLinks = 0 - } - username := "root" - groupname := "root" - mtime := dirent.ModTime() - monthStr := mtime.Month().String()[0:3] - day := mtime.Day() - year := mtime.Year() - now := time.Now() - isOld := mtime.Before(now.Add(-time.Hour * 24 * 365 / 2)) - - yearOrTime := fmt.Sprintf("%02d:%02d", mtime.Hour(), mtime.Minute()) - if isOld { - yearOrTime = fmt.Sprintf("%d", year) - } - - return fmt.Sprintf("%s %4d %-8s %-8s %8d %s %2d %5s %s", typeword, numLinks, username, groupname, dirent.Size(), monthStr, day, yearOrTime, dirent.Name()) -} -- cgit v1.2.3