Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrWatcherClosed = fsnotify.ErrClosed
ErrWatcherClosed indicates that a workspace watcher was closed.
Functions ¶
This section is empty.
Types ¶
type DiscoveredRepo ¶
type DiscoveredRepo struct {
Path string // absolute path to the repository
Name string // directory name
Remote string // origin remote URL
}
DiscoveredRepo represents a git repository found during scanning.
func ScanRepoDirs ¶
func ScanRepoDirs(ctx context.Context, logger zerolog.Logger, dirs []string, gitExec git.Git) ([]DiscoveredRepo, error)
ScanRepoDirs scans parent directories for git repositories. Each directory in dirs is expected to contain subdirectories that are git repos. Repositories that fail to scan are silently skipped.
type Watcher ¶
type Watcher struct {
// contains filtered or unexported fields
}
Watcher reports changes that can alter the repositories discovered in a configured workspace directory.
func NewWatcher ¶
NewWatcher creates a watcher for configured workspace directories.
Click to show internal directories.
Click to hide internal directories.