Documentation ¶
Index ¶
- Constants
- func GetPlatformSpecificMountOptionsForTest() []fuse.MountOption
- func GetPlatformUsageString() string
- func MakeFuseDebugFn(log logger.Logger, superVerbose bool) func(msg interface{})
- func MakeFuseVDebugFn(vlog *libkb.VDebugLog, superVerbose bool) func(msg interface{})
- func Start(options StartOptions, kbCtx libkbfs.Context) *libfs.Error
- type Alias
- type CtxTagKey
- type DebugServerFile
- type Dir
- func (d *Dir) Access(ctx context.Context, r *fuse.AccessRequest) (err error)
- func (d *Dir) Attr(ctx context.Context, a *fuse.Attr) (err error)
- func (d *Dir) Create(ctx context.Context, req *fuse.CreateRequest, resp *fuse.CreateResponse) (node fs.Node, handle fs.Handle, err error)
- func (d *Dir) Forget()
- func (d *Dir) Fsync(ctx context.Context, req *fuse.FsyncRequest) (err error)
- func (d *Dir) Link(_ context.Context, _ *fuse.LinkRequest, _ fs.Node) (fs.Node, error)
- func (d *Dir) Lookup(ctx context.Context, req *fuse.LookupRequest, resp *fuse.LookupResponse) (node fs.Node, err error)
- func (d *Dir) Mkdir(ctx context.Context, req *fuse.MkdirRequest) (node fs.Node, err error)
- func (d *Dir) ReadDirAll(ctx context.Context) (res []fuse.Dirent, err error)
- func (d *Dir) Remove(ctx context.Context, req *fuse.RemoveRequest) (err error)
- func (d *Dir) Rename(ctx context.Context, req *fuse.RenameRequest, newDir fs.Node) (err error)
- func (d *Dir) Setattr(ctx context.Context, req *fuse.SetattrRequest, resp *fuse.SetattrResponse) (err error)
- func (d *Dir) Symlink(ctx context.Context, req *fuse.SymlinkRequest) (node fs.Node, err error)
- type DirInterface
- type FS
- func (f *FS) LaunchNotificationProcessor(ctx context.Context)
- func (f *FS) NotificationGroupWait()
- func (f *FS) Root() (fs.Node, error)
- func (f *FS) Serve(ctx context.Context) error
- func (f *FS) SetFuseConn(fuse *fs.Server, conn *fuse.Conn)
- func (f *FS) Statfs(ctx context.Context, req *fuse.StatfsRequest, resp *fuse.StatfsResponse) error
- func (f *FS) UserChanged(ctx context.Context, oldName, newName kbname.NormalizedUsername)
- func (f *FS) WithContext(ctx context.Context) context.Context
- type File
- func (f *File) Access(ctx context.Context, r *fuse.AccessRequest) (err error)
- func (f *File) Attr(ctx context.Context, a *fuse.Attr) (err error)
- func (f *File) Forget()
- func (f *File) Fsync(ctx context.Context, req *fuse.FsyncRequest) (err error)
- func (f *File) Read(ctx context.Context, req *fuse.ReadRequest, resp *fuse.ReadResponse) (err error)
- func (f *File) Setattr(ctx context.Context, req *fuse.SetattrRequest, resp *fuse.SetattrResponse) (err error)
- func (f *File) Write(ctx context.Context, req *fuse.WriteRequest, resp *fuse.WriteResponse) (err error)
- type Folder
- type FolderList
- func (*FolderList) Access(ctx context.Context, r *fuse.AccessRequest) error
- func (fl *FolderList) Attr(ctx context.Context, a *fuse.Attr) error
- func (fl *FolderList) Create(ctx context.Context, req *fuse.CreateRequest, resp *fuse.CreateResponse) (_ fs.Node, _ fs.Handle, err error)
- func (fl *FolderList) Forget()
- func (fl *FolderList) Link(_ context.Context, _ *fuse.LinkRequest, _ fs.Node) (fs.Node, error)
- func (fl *FolderList) Lookup(ctx context.Context, req *fuse.LookupRequest, resp *fuse.LookupResponse) (node fs.Node, err error)
- func (fl *FolderList) Mkdir(ctx context.Context, req *fuse.MkdirRequest) (_ fs.Node, err error)
- func (fl *FolderList) PathType() tlfhandle.PathType
- func (fl *FolderList) ReadDirAll(ctx context.Context) (res []fuse.Dirent, err error)
- func (fl *FolderList) Remove(ctx context.Context, req *fuse.RemoveRequest) (err error)
- func (fl *FolderList) Symlink(_ context.Context, _ *fuse.SymlinkRequest) (fs.Node, error)
- type JournalControlFile
- type NoXattrHandler
- type PlatformParams
- type PrefetchFile
- type ProfileList
- func (ProfileList) Attr(_ context.Context, a *fuse.Attr) error
- func (pl ProfileList) Lookup(_ context.Context, req *fuse.LookupRequest, resp *fuse.LookupResponse) (node fs.Node, err error)
- func (pl ProfileList) ReadDirAll(_ context.Context) (res []fuse.Dirent, err error)
- func (ProfileList) Remove(_ context.Context, req *fuse.RemoveRequest) (err error)
- type ReclaimQuotaFile
- type RekeyFile
- type ResetCachesFile
- type Root
- func (*Root) Access(ctx context.Context, r *fuse.AccessRequest) error
- func (*Root) Attr(ctx context.Context, a *fuse.Attr) error
- func (r *Root) Create(ctx context.Context, req *fuse.CreateRequest, resp *fuse.CreateResponse) (_ fs.Node, _ fs.Handle, err error)
- func (r *Root) Link(_ context.Context, _ *fuse.LinkRequest, _ fs.Node) (fs.Node, error)
- func (r *Root) Lookup(ctx context.Context, req *fuse.LookupRequest, resp *fuse.LookupResponse) (_ fs.Node, err error)
- func (r *Root) Mkdir(ctx context.Context, req *fuse.MkdirRequest) (_ fs.Node, err error)
- func (r *Root) PathType() tlfhandle.PathType
- func (r *Root) ReadDirAll(ctx context.Context) (res []fuse.Dirent, err error)
- func (r *Root) Symlink(_ context.Context, _ *fuse.SymlinkRequest) (fs.Node, error)
- type SpecialReadFile
- func NewArchiveRelTimeFile(fs *FS, handle *tlfhandle.Handle, filename string, entryValid *time.Duration) *SpecialReadFile
- func NewErrorFile(fs *FS, entryValid *time.Duration) *SpecialReadFile
- func NewFileInfoFile(fs *FS, dir libkbfs.Node, name string, entryValid *time.Duration) *SpecialReadFile
- func NewMetricsFile(fs *FS, entryValid *time.Duration) *SpecialReadFile
- func NewNonTLFStatusFile(fs *FS, entryValid *time.Duration) *SpecialReadFile
- func NewOpenFileCountFile(folder *Folder, entryValid *time.Duration) *SpecialReadFile
- func NewTlfEditHistoryFile(folder *Folder, entryValid *time.Duration) *SpecialReadFile
- func NewUserEditHistoryFile(folder *Folder, entryValid *time.Duration) *SpecialReadFile
- type StartOptions
- type Symlink
- type SyncControlFile
- type SyncFromServerFile
- type TLF
- func (tlf *TLF) Access(ctx context.Context, r *fuse.AccessRequest) error
- func (tlf *TLF) Attr(ctx context.Context, a *fuse.Attr) error
- func (tlf *TLF) Create(ctx context.Context, req *fuse.CreateRequest, resp *fuse.CreateResponse) (fs.Node, fs.Handle, error)
- func (tlf *TLF) Forget()
- func (tlf *TLF) Fsync(ctx context.Context, req *fuse.FsyncRequest) (err error)
- func (tlf *TLF) Link(_ context.Context, _ *fuse.LinkRequest, _ fs.Node) (fs.Node, error)
- func (tlf *TLF) Lookup(ctx context.Context, req *fuse.LookupRequest, resp *fuse.LookupResponse) (fs.Node, error)
- func (tlf *TLF) Mkdir(ctx context.Context, req *fuse.MkdirRequest) (_ fs.Node, err error)
- func (tlf *TLF) Open(ctx context.Context, req *fuse.OpenRequest, resp *fuse.OpenResponse) (fs.Handle, error)
- func (tlf *TLF) ReadDirAll(ctx context.Context) ([]fuse.Dirent, error)
- func (tlf *TLF) Remove(ctx context.Context, req *fuse.RemoveRequest) error
- func (tlf *TLF) Rename(ctx context.Context, req *fuse.RenameRequest, newDir fs.Node) error
- func (tlf *TLF) Setattr(ctx context.Context, req *fuse.SetattrRequest, resp *fuse.SetattrResponse) error
- func (tlf *TLF) Symlink(ctx context.Context, req *fuse.SymlinkRequest) (fs.Node, error)
- type UnstageFile
- type UpdatesFile
- type XattrHandler
Constants ¶
const ( // PublicName is the name of the parent of all public top-level folders. PublicName = "public" // PrivateName is the name of the parent of all private top-level folders. PrivateName = "private" // TeamName is the name of the parent of all team top-level folders. TeamName = "team" // CtxOpID is the display name for the unique operation FUSE ID tag. CtxOpID = "FID" )
Variables ¶
This section is empty.
Functions ¶
func GetPlatformSpecificMountOptionsForTest ¶
func GetPlatformSpecificMountOptionsForTest() []fuse.MountOption
GetPlatformSpecificMountOptionsForTest makes cross-platform tests work
func GetPlatformUsageString ¶
func GetPlatformUsageString() string
GetPlatformUsageString returns a string to be included in a usage string corresponding to the flags added by AddPlatformFlags.
func MakeFuseDebugFn ¶
MakeFuseDebugFn returns a function that logs its argument to the given log, suitable to assign to fuse.Debug.
func MakeFuseVDebugFn ¶
MakeFuseVDebugFn returns a function that logs its argument to the given vlog at level 1, suitable to assign to fuse.Debug.
Types ¶
type Alias ¶
type Alias struct {
// contains filtered or unexported fields
}
Alias represents an alias. A use case for it is a top-level folder accessed through its non-canonical name.
type DebugServerFile ¶
type DebugServerFile struct {
// contains filtered or unexported fields
}
DebugServerFile represents a write-only file where any write of at least one byte triggers either disabling or enabling the debug server. For enabling, the port number to listen on (with localhost) must be what is written, e.g.
echo 8080 > /keybase/.kbfs_enable_debug_server
will spawn the HTTP debug server on port 8080.
func (*DebugServerFile) Write ¶
func (f *DebugServerFile) Write(ctx context.Context, req *fuse.WriteRequest, resp *fuse.WriteResponse) (err error)
Write implements the fs.HandleWriter interface for DebugServerFile.
type Dir ¶
type Dir struct { XattrHandler // contains filtered or unexported fields }
Dir represents a subdirectory of a KBFS top-level folder (including the TLF root directory itself).
func (*Dir) Access ¶
Access implements the fs.NodeAccesser interface for File. See comment for File.Access for more details.
func (*Dir) Create ¶
func (d *Dir) Create(ctx context.Context, req *fuse.CreateRequest, resp *fuse.CreateResponse) (node fs.Node, handle fs.Handle, err error)
Create implements the fs.NodeCreater interface for Dir.
func (*Dir) Lookup ¶
func (d *Dir) Lookup(ctx context.Context, req *fuse.LookupRequest, resp *fuse.LookupResponse) (node fs.Node, err error)
Lookup implements the fs.NodeRequestLookuper interface for Dir.
func (*Dir) ReadDirAll ¶
ReadDirAll implements the fs.NodeReadDirAller interface for Dir.
func (*Dir) Setattr ¶
func (d *Dir) Setattr(ctx context.Context, req *fuse.SetattrRequest, resp *fuse.SetattrResponse) (err error)
Setattr implements the fs.NodeSetattrer interface for Dir.
type DirInterface ¶
type DirInterface interface { fs.Node fs.NodeAccesser fs.NodeRequestLookuper fs.NodeCreater fs.NodeMkdirer fs.NodeSymlinker fs.NodeRenamer fs.NodeRemover fs.Handle fs.HandleReadDirAller fs.NodeForgetter fs.NodeSetattrer fs.NodeFsyncer fs.NodeGetxattrer fs.NodeSetxattrer }
DirInterface gathers all the interfaces a Dir or something that wraps a Dir should implement.
type FS ¶
type FS struct {
// contains filtered or unexported fields
}
FS implements the newfuse FS interface for KBFS.
func NewFS ¶
NewFS creates an FS. Note that this isn't the only constructor; see makeFS in libfuse/mount_test.go.
func (*FS) LaunchNotificationProcessor ¶
LaunchNotificationProcessor launches the notification processor.
func (*FS) NotificationGroupWait ¶
func (f *FS) NotificationGroupWait()
NotificationGroupWait - wait on the notification group.
func (*FS) SetFuseConn ¶
SetFuseConn sets fuse connection for this FS.
func (*FS) Statfs ¶
func (f *FS) Statfs(ctx context.Context, req *fuse.StatfsRequest, resp *fuse.StatfsResponse) error
Statfs implements the fs.FSStatfser interface for FS.
func (*FS) UserChanged ¶
func (f *FS) UserChanged(ctx context.Context, oldName, newName kbname.NormalizedUsername)
UserChanged is called from libfs.
func (*FS) WithContext ¶
WithContext adds app- and request-specific values to the context. libkbfs.NewContextWithCancellationDelayer is called before returning the context to ensure the cancellation is controllable.
It is called by FUSE for normal runs, but may be called explicitly in other settings, such as tests.
type File ¶
type File struct { XattrHandler // contains filtered or unexported fields }
File represents KBFS files.
func (*File) Access ¶
Access implements the fs.NodeAccesser interface for File. This is necessary for macOS to correctly identify plaintext files as plaintext. If not implemented, bazil-fuse returns a nil error for every call, so when macOS checks for executable bit using Access (instead of Attr!), it gets a success, which makes it think the file is executable, yielding a "Unix executable" UTI.
func (*File) Read ¶
func (f *File) Read(ctx context.Context, req *fuse.ReadRequest, resp *fuse.ReadResponse) (err error)
Read implements the fs.HandleReader interface for File.
func (*File) Setattr ¶
func (f *File) Setattr(ctx context.Context, req *fuse.SetattrRequest, resp *fuse.SetattrResponse) (err error)
Setattr implements the fs.NodeSetattrer interface for File.
func (*File) Write ¶
func (f *File) Write(ctx context.Context, req *fuse.WriteRequest, resp *fuse.WriteResponse) (err error)
Write implements the fs.HandleWriter interface for File.
type Folder ¶
type Folder struct {
// contains filtered or unexported fields
}
Folder represents the info shared among all nodes of a KBFS top-level folder.
func (*Folder) BatchChanges ¶
func (f *Folder) BatchChanges( ctx context.Context, changes []libkbfs.NodeChange, _ []libkbfs.NodeID)
BatchChanges is called for changes originating anywhere, including other hosts.
func (*Folder) LocalChange ¶
LocalChange is called for changes originating within in this process.
type FolderList ¶
type FolderList struct {
// contains filtered or unexported fields
}
FolderList is a node that can list all of the logged-in user's favorite top-level folders, on either a public or private basis.
func (*FolderList) Access ¶
func (*FolderList) Access(ctx context.Context, r *fuse.AccessRequest) error
Access implements fs.NodeAccesser interface for *FolderList.
func (*FolderList) Create ¶
func (fl *FolderList) Create(ctx context.Context, req *fuse.CreateRequest, resp *fuse.CreateResponse) (_ fs.Node, _ fs.Handle, err error)
Create implements the fs.NodeCreater interface for FolderList.
func (*FolderList) Link ¶
func (fl *FolderList) Link( _ context.Context, _ *fuse.LinkRequest, _ fs.Node) (fs.Node, error)
Link implements the fs.NodeLinker interface for FolderList.
func (*FolderList) Lookup ¶
func (fl *FolderList) Lookup(ctx context.Context, req *fuse.LookupRequest, resp *fuse.LookupResponse) (node fs.Node, err error)
Lookup implements the fs.NodeRequestLookuper interface.
func (*FolderList) Mkdir ¶
func (fl *FolderList) Mkdir(ctx context.Context, req *fuse.MkdirRequest) (_ fs.Node, err error)
Mkdir implements the fs.NodeMkdirer interface for FolderList.
func (*FolderList) PathType ¶
func (fl *FolderList) PathType() tlfhandle.PathType
PathType returns PathType for this folder
func (*FolderList) ReadDirAll ¶
ReadDirAll implements the ReadDirAll interface.
func (*FolderList) Remove ¶
func (fl *FolderList) Remove(ctx context.Context, req *fuse.RemoveRequest) (err error)
Remove implements the fs.NodeRemover interface for FolderList.
func (*FolderList) Symlink ¶
func (fl *FolderList) Symlink( _ context.Context, _ *fuse.SymlinkRequest) (fs.Node, error)
Symlink implements the fs.NodeSymlinker interface for FolderList.
type JournalControlFile ¶
type JournalControlFile struct {
// contains filtered or unexported fields
}
JournalControlFile is a special file used to control journal settings.
func (*JournalControlFile) Write ¶
func (f *JournalControlFile) Write(ctx context.Context, req *fuse.WriteRequest, resp *fuse.WriteResponse) (err error)
Write implements the fs.HandleWriter interface for JournalControlFile.
type NoXattrHandler ¶
type NoXattrHandler struct{}
NoXattrHandler is a Xattr handler that always returns fuse.ENOTSUP.
func (NoXattrHandler) Getxattr ¶
func (h NoXattrHandler) Getxattr(context.Context, *fuse.GetxattrRequest, *fuse.GetxattrResponse) error
Getxattr implements the fs.NodeGetxattrer interface.
func (NoXattrHandler) Removexattr ¶
func (h NoXattrHandler) Removexattr(context.Context, *fuse.RemovexattrRequest) error
Removexattr implements the fs.NodeRemovexattrer interface.
func (NoXattrHandler) Setxattr ¶
func (h NoXattrHandler) Setxattr(context.Context, *fuse.SetxattrRequest) error
Setxattr implements the fs.NodeSetxattrer interface.
type PlatformParams ¶
type PlatformParams struct{}
PlatformParams contains all platform-specific parameters to be passed to New{Default,Force}Mounter.
func AddPlatformFlags ¶
func AddPlatformFlags(flags *flag.FlagSet) *PlatformParams
AddPlatformFlags adds platform-specific flags to the given FlagSet and returns a PlatformParams object that will be filled in when the given FlagSet is parsed.
type PrefetchFile ¶
type PrefetchFile struct {
// contains filtered or unexported fields
}
PrefetchFile represents a write-only file where any write of at least one byte triggers either disabling or enabling prefetching. It is mainly useful for testing.
func (*PrefetchFile) Write ¶
func (f *PrefetchFile) Write(ctx context.Context, req *fuse.WriteRequest, resp *fuse.WriteResponse) (err error)
Write implements the fs.HandleWriter interface for PrefetchFile.
type ProfileList ¶
type ProfileList struct {
// contains filtered or unexported fields
}
ProfileList is a node that can list all of the available profiles.
func (ProfileList) Lookup ¶
func (pl ProfileList) Lookup(_ context.Context, req *fuse.LookupRequest, resp *fuse.LookupResponse) (node fs.Node, err error)
Lookup implements the fs.NodeRequestLookuper interface.
func (ProfileList) ReadDirAll ¶
ReadDirAll implements the ReadDirAll interface.
func (ProfileList) Remove ¶
func (ProfileList) Remove(_ context.Context, req *fuse.RemoveRequest) (err error)
Remove implements the fs.NodeRemover interface for ProfileList.
type ReclaimQuotaFile ¶
type ReclaimQuotaFile struct {
// contains filtered or unexported fields
}
ReclaimQuotaFile represents a write-only file when any write of at least one byte triggers a quota reclamation of the folder.
func (*ReclaimQuotaFile) Write ¶
func (f *ReclaimQuotaFile) Write(ctx context.Context, req *fuse.WriteRequest, resp *fuse.WriteResponse) (err error)
Write implements the fs.HandleWriter interface for ReclaimQuotaFile. Note a write triggers quota reclamation, but does not wait for it to finish. If you want to wait, write to SyncFromServerFileName.
type RekeyFile ¶
type RekeyFile struct {
// contains filtered or unexported fields
}
RekeyFile represents a write-only file when any write of at least one byte triggers a rekey of the folder.
func (*RekeyFile) Write ¶
func (f *RekeyFile) Write(ctx context.Context, req *fuse.WriteRequest, resp *fuse.WriteResponse) (err error)
Write implements the fs.HandleWriter interface for RekeyFile.
type ResetCachesFile ¶
type ResetCachesFile struct {
// contains filtered or unexported fields
}
ResetCachesFile represents a write-only file where any write of at least one byte triggers the resetting of all data caches. It can be reached from any directory under the FUSE mountpoint. Note that it does not clear the *node* cache, which means that the BlockPointers for existing nodes are still cached, such that directory listings can still be implicitly cached for nodes still being held by the kernel.
func (*ResetCachesFile) Write ¶
func (f *ResetCachesFile) Write(ctx context.Context, req *fuse.WriteRequest, resp *fuse.WriteResponse) (err error)
Write implements the fs.HandleWriter interface for ResetCachesFile.
type Root ¶
type Root struct {
// contains filtered or unexported fields
}
Root represents the root of the KBFS file system.
func (*Root) Create ¶
func (r *Root) Create(ctx context.Context, req *fuse.CreateRequest, resp *fuse.CreateResponse) (_ fs.Node, _ fs.Handle, err error)
Create implements the fs.NodeCreater interface for Root.
func (*Root) Lookup ¶
func (r *Root) Lookup(ctx context.Context, req *fuse.LookupRequest, resp *fuse.LookupResponse) (_ fs.Node, err error)
Lookup implements the fs.NodeRequestLookuper interface for Root.
func (*Root) ReadDirAll ¶
ReadDirAll implements the ReadDirAll interface for Root.
type SpecialReadFile ¶
type SpecialReadFile struct {
// contains filtered or unexported fields
}
SpecialReadFile represents a file whose contents are determined by a function.
func NewArchiveRelTimeFile ¶
func NewArchiveRelTimeFile( fs *FS, handle *tlfhandle.Handle, filename string, entryValid *time.Duration) *SpecialReadFile
NewArchiveRelTimeFile returns a special read file that contains a by-revision directory name that corresponds to the given relative time string for the given folder.
func NewErrorFile ¶
func NewErrorFile(fs *FS, entryValid *time.Duration) *SpecialReadFile
NewErrorFile returns a special read file that contains a text representation of the last few KBFS errors.
func NewFileInfoFile ¶
func NewFileInfoFile( fs *FS, dir libkbfs.Node, name string, entryValid *time.Duration) *SpecialReadFile
NewFileInfoFile returns a special file that contains a text representation of a file's KBFS metadata.
func NewMetricsFile ¶
func NewMetricsFile(fs *FS, entryValid *time.Duration) *SpecialReadFile
NewMetricsFile returns a special read file that contains a text representation of all metrics.
func NewNonTLFStatusFile ¶
func NewNonTLFStatusFile(fs *FS, entryValid *time.Duration) *SpecialReadFile
NewNonTLFStatusFile returns a special read file that contains a text representation of the global KBFS status.
func NewOpenFileCountFile ¶
func NewOpenFileCountFile( folder *Folder, entryValid *time.Duration) *SpecialReadFile
NewOpenFileCountFile returns a special read file that contains the number of files and directories currently being held open by the OS.
func NewTlfEditHistoryFile ¶
func NewTlfEditHistoryFile( folder *Folder, entryValid *time.Duration) *SpecialReadFile
NewTlfEditHistoryFile returns a special read file that contains a text representation of the file edit history for that TLF.
func NewUserEditHistoryFile ¶
func NewUserEditHistoryFile( folder *Folder, entryValid *time.Duration) *SpecialReadFile
NewUserEditHistoryFile returns a special read file that contains a text representation of the file edit history for the logged-in user.
func (*SpecialReadFile) Open ¶
func (f *SpecialReadFile) Open(ctx context.Context, req *fuse.OpenRequest, resp *fuse.OpenResponse) (fs.Handle, error)
Open implements the fs.NodeOpener interface for SpecialReadFile.
type StartOptions ¶
type StartOptions struct { KbfsParams libkbfs.InitParams PlatformParams PlatformParams RuntimeDir string Label string ForceMount bool MountErrorIsFatal bool SkipMount bool MountPoint string }
StartOptions are options for starting up
type Symlink ¶
type Symlink struct {
// contains filtered or unexported fields
}
Symlink represents KBFS symlinks.
type SyncControlFile ¶
type SyncControlFile struct {
// contains filtered or unexported fields
}
SyncControlFile is a special file used to control sync settings.
func (*SyncControlFile) Write ¶
func (f *SyncControlFile) Write(ctx context.Context, req *fuse.WriteRequest, resp *fuse.WriteResponse) (err error)
Write implements the fs.HandleWriter interface for SyncControlFile.
type SyncFromServerFile ¶
type SyncFromServerFile struct {
// contains filtered or unexported fields
}
SyncFromServerFile represents a write-only file when any write of at least one byte triggers a sync of the folder from the server. A sync:
- Waits for any outstanding conflict resolution tasks to finish (and it fails if the TLF is still in staged mode after waiting for CR).
- Checks with the server for what the latest revision is for the folder.
- Fetches and applies any missing revisions.
- Waits for all outstanding block archive tasks to complete.
- Waits for all outstanding quota reclamation tasks to complete.
func (*SyncFromServerFile) Write ¶
func (f *SyncFromServerFile) Write(ctx context.Context, req *fuse.WriteRequest, resp *fuse.WriteResponse) (err error)
Write implements the fs.HandleWriter interface for SyncFromServerFile.
type TLF ¶
type TLF struct { // We never set quarantine on TLF roots, so don't bother with getting a dir // and calling the method on it. Instead, just use this dumb handler to // always return fuse.ENOTSUP. NoXattrHandler // contains filtered or unexported fields }
TLF represents the root directory of a TLF. It wraps a lazy-loaded Dir.
func (*TLF) Create ¶
func (tlf *TLF) Create(ctx context.Context, req *fuse.CreateRequest, resp *fuse.CreateResponse) (fs.Node, fs.Handle, error)
Create implements the fs.NodeCreater interface for TLF.
func (*TLF) Lookup ¶
func (tlf *TLF) Lookup(ctx context.Context, req *fuse.LookupRequest, resp *fuse.LookupResponse) (fs.Node, error)
Lookup implements the fs.NodeRequestLookuper interface for TLF.
func (*TLF) Open ¶
func (tlf *TLF) Open(ctx context.Context, req *fuse.OpenRequest, resp *fuse.OpenResponse) (fs.Handle, error)
Open implements the fs.NodeOpener interface for TLF.
func (*TLF) ReadDirAll ¶
ReadDirAll implements the fs.NodeReadDirAller interface for TLF.
func (*TLF) Setattr ¶
func (tlf *TLF) Setattr(ctx context.Context, req *fuse.SetattrRequest, resp *fuse.SetattrResponse) error
Setattr implements the fs.NodeSetattrer interface for TLF.
type UnstageFile ¶
type UnstageFile struct {
// contains filtered or unexported fields
}
UnstageFile represents a write-only file when any write of at least one byte triggers unstaging all unmerged commits and fast-forwarding to the current master.
func (*UnstageFile) Write ¶
func (f *UnstageFile) Write(ctx context.Context, req *fuse.WriteRequest, resp *fuse.WriteResponse) (err error)
Write implements the fs.HandleWriter interface for UnstageFile.
type UpdatesFile ¶
type UpdatesFile struct {
// contains filtered or unexported fields
}
UpdatesFile represents a write-only file where any write of at least one byte triggers either disabling remote folder updates and conflict resolution, or re-enabling both. It is mainly useful for testing.
func (*UpdatesFile) Write ¶
func (f *UpdatesFile) Write(ctx context.Context, req *fuse.WriteRequest, resp *fuse.WriteResponse) (err error)
Write implements the fs.HandleWriter interface for UpdatesFile.
type XattrHandler ¶
type XattrHandler interface { fs.NodeGetxattrer fs.NodeSetxattrer fs.NodeRemovexattrer }
XattrHandler is an interface that includes fuse Get/Set/Remove calls for xattr.
func NewQuarantineXattrHandler ¶
func NewQuarantineXattrHandler(libkbfs.Node, *Folder) XattrHandler
NewQuarantineXattrHandler returns a handler that doesn't handle Xattr calls on this platform.
Source Files ¶
- alias.go
- archive_reltime_file.go
- block_size.go
- common.go
- debug.go
- debug_server_file.go
- dir.go
- error_file.go
- errors.go
- external_file.go
- file.go
- file_info_file.go
- folderlist.go
- fs.go
- fs_default.go
- journal_control_file.go
- metrics_file.go
- mounter.go
- mounter_non_osx.go
- open_file_count_file.go
- platform_flags_non_osx.go
- prefetch_file.go
- profilelist.go
- quarantine.go
- quarantine_others.go
- reclaim_quota_file.go
- rekey_file.go
- reset_caches_file.go
- special_files.go
- special_read_file.go
- start.go
- status_file.go
- symlink.go
- sync_control_file.go
- sync_from_server_file.go
- tlf.go
- tlf_edit_history_file.go
- unstage_file.go
- updates_file.go
- user_edit_history_file.go