Documentation
¶
Index ¶
- func GetDefaultConfigPath() string
- type Config
- func (c *Config) BuildMaps()
- func (c *Config) ExclusionReason(path string) string
- func (c *Config) FindIndexPath(path string) *IndexPath
- func (c *Config) GetDepth(path string) int
- func (c *Config) GetMaxDepth(path string) int
- func (c *Config) IsTextFile(path string) bool
- func (c *Config) Save(path string) error
- func (c *Config) ShouldIndexDir(path string) bool
- func (c *Config) ShouldIndexFile(path string) bool
- type IndexPath
- type IndexStats
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetDefaultConfigPath ¶
func GetDefaultConfigPath() string
Types ¶
type Config ¶
type Config struct {
IndexPath string `toml:"index_path"`
ListenAddr string `toml:"listen_addr"`
MaxFileBytes int64 `toml:"max_file_bytes"`
WorkerCount int `toml:"worker_count"`
IndexPaths []IndexPath `toml:"index_paths"`
TextExts []string `toml:"text_extensions"`
IndexAllFiles bool `toml:"index_all_files"`
IndexXattrTags bool `toml:"index_xattr_tags"`
RootDir string `toml:"root_dir,omitempty"`
MaxDepth int `toml:"max_depth,omitempty"`
ExcludeHidden bool `toml:"exclude_hidden,omitempty"`
ExcludeDirs []string `toml:"exclude_dirs,omitempty"`
// contains filtered or unexported fields
}
func (*Config) ExclusionReason ¶ added in v0.2.0
func (*Config) FindIndexPath ¶ added in v0.2.0
func (*Config) GetMaxDepth ¶
func (*Config) IsTextFile ¶
func (*Config) ShouldIndexDir ¶
func (*Config) ShouldIndexFile ¶
type IndexPath ¶
type IndexPath struct {
Path string `toml:"path"`
MaxDepth int `toml:"max_depth"`
ExcludeHidden bool `toml:"exclude_hidden"`
ExcludeDirs []string `toml:"exclude_dirs"`
ExtractExif bool `toml:"extract_exif"`
ExtractXattrTags bool `toml:"extract_xattr_tags"`
Watch *bool `toml:"watch,omitempty"` // nil = true (default), false = skip fsnotify
// contains filtered or unexported fields
}
func (*IndexPath) ShouldWatch ¶ added in v0.1.0
Click to show internal directories.
Click to hide internal directories.