github.com/criteo/command-launcher@v0.0.0-20230407142452-fb616f546e98/internal/repository/repo-index.go (about)

     1  package repository
     2  
     3  import "github.com/criteo/command-launcher/internal/command"
     4  
     5  type RepoIndex interface {
     6  	/* write interfaces */
     7  	Load(repoDir string) error
     8  	Add(pkg command.PackageManifest, repoDir string, pkgDirName string) error
     9  	Remove(pkgName string, repoDir string) error
    10  	Update(pkg command.PackageManifest, repoDir string, pkgDirName string) error
    11  
    12  	/* read interfaces */
    13  	AllPackages() []command.PackageManifest
    14  	AllCommands() []command.Command
    15  	GroupCommands() []command.Command
    16  	ExecutableCommands() []command.Command
    17  	SystemLoginCommand() command.Command
    18  	SystemMetricsCommand() command.Command
    19  	Package(name string) (command.PackageManifest, error)
    20  	Command(pkg string, group string, name string) (command.Command, error)
    21  }