Documentation ¶
Index ¶
- Constants
- Variables
- func IsAbsolute() interfaces.ServiceCrudOption
- func NewFsService(opts ...Option) (svc2 interfaces.FsService, err error)
- type FilerFileInfoSlice
- type Option
- type Service
- func (svc *Service) Commit(msg string) (err error)
- func (svc *Service) Copy(path, newPath string, opts ...interfaces.ServiceCrudOption) (err error)
- func (svc *Service) Delete(path string, opts ...interfaces.ServiceCrudOption) (err error)
- func (svc *Service) GetConfigPath() string
- func (svc *Service) GetFile(path string, opts ...interfaces.ServiceCrudOption) (data []byte, err error)
- func (svc *Service) GetFileInfo(path string, opts ...interfaces.ServiceCrudOption) (file interfaces.FsFileInfo, err error)
- func (svc *Service) GetFs() (fs cfs.Manager)
- func (svc *Service) GetFsPath() (path string)
- func (svc *Service) GetGitClient() (c *vcs.GitClient)
- func (svc *Service) GetRepoPath() (path string)
- func (svc *Service) GetWorkspacePath() (path string)
- func (svc *Service) List(path string, opts ...interfaces.ServiceCrudOption) (files []interfaces.FsFileInfo, err error)
- func (svc *Service) Rename(path, newPath string, opts ...interfaces.ServiceCrudOption) (err error)
- func (svc *Service) Save(path string, data []byte, opts ...interfaces.ServiceCrudOption) (err error)
- func (svc *Service) SetConfigPath(path string)
- func (svc *Service) SetFsPath(path string)
- func (svc *Service) SetRepoPath(path string)
- func (svc *Service) SetWorkspacePath(path string)
- func (svc *Service) SyncToFs(opts ...interfaces.ServiceCrudOption) (err error)
- func (svc *Service) SyncToWorkspace() (err error)
Constants ¶
View Source
const DefaultFsPath = "/fs"
Variables ¶
View Source
var DefaultRepoPath string
View Source
var DefaultWorkspacePath string
Functions ¶
func IsAbsolute ¶
func IsAbsolute() interfaces.ServiceCrudOption
func NewFsService ¶
func NewFsService(opts ...Option) (svc2 interfaces.FsService, err error)
Types ¶
type FilerFileInfoSlice ¶
type FilerFileInfoSlice []goseaweedfs.FilerFileInfo
func (FilerFileInfoSlice) Len ¶
func (f FilerFileInfoSlice) Len() int
func (FilerFileInfoSlice) Less ¶
func (f FilerFileInfoSlice) Less(i, j int) bool
func (FilerFileInfoSlice) Swap ¶
func (f FilerFileInfoSlice) Swap(i, j int)
type Option ¶
type Option func(svc interfaces.FsService)
func WithConfigPath ¶
func WithFsPath ¶
func WithRepoPath ¶
func WithWorkspacePath ¶
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func (*Service) Copy ¶
func (svc *Service) Copy(path, newPath string, opts ...interfaces.ServiceCrudOption) (err error)
func (*Service) Delete ¶
func (svc *Service) Delete(path string, opts ...interfaces.ServiceCrudOption) (err error)
func (*Service) GetConfigPath ¶
func (*Service) GetFile ¶
func (svc *Service) GetFile(path string, opts ...interfaces.ServiceCrudOption) (data []byte, err error)
func (*Service) GetFileInfo ¶
func (svc *Service) GetFileInfo(path string, opts ...interfaces.ServiceCrudOption) (file interfaces.FsFileInfo, err error)
func (*Service) GetGitClient ¶
func (*Service) GetRepoPath ¶
func (*Service) GetWorkspacePath ¶
func (*Service) List ¶
func (svc *Service) List(path string, opts ...interfaces.ServiceCrudOption) (files []interfaces.FsFileInfo, err error)
func (*Service) Rename ¶
func (svc *Service) Rename(path, newPath string, opts ...interfaces.ServiceCrudOption) (err error)
func (*Service) Save ¶
func (svc *Service) Save(path string, data []byte, opts ...interfaces.ServiceCrudOption) (err error)
func (*Service) SetConfigPath ¶
func (*Service) SetRepoPath ¶
func (*Service) SetWorkspacePath ¶
func (*Service) SyncToFs ¶
func (svc *Service) SyncToFs(opts ...interfaces.ServiceCrudOption) (err error)
SyncToFs sync from repo/workspace to fs
func (*Service) SyncToWorkspace ¶
SyncToWorkspace sync from fs to workspace
Click to show internal directories.
Click to hide internal directories.