Documentation
¶
Index ¶
- func CheckOrCreateDir(path string) error
- func Clone(path string, repoName string, version string) error
- func CreateNewPpmConfig(path string) error
- func DoesPathExist(path string) (bool, error)
- func GetPluginName(name string) string
- func GetVersionOrNot(dependency string) (string, string)
- func IndexOf(target string, data []string) int
- func PlayLoadingAnim(loading chan interface{})
- func PrintDone()
- func StringSliceContains(target string, data []string) bool
- func Update(path string) error
- type PpmConfig
- func (ppm *PpmConfig) AddDependency(dependency string)
- func (ppm *PpmConfig) AddSubDependency(dependency string)
- func (ppm PpmConfig) HasDependency(dependency string) bool
- func (ppm PpmConfig) HasSubDependency(dependency string) bool
- func (ppm PpmConfig) PrettyPrint()
- func (ppm *PpmConfig) RemoveAllDependencies()
- func (ppm *PpmConfig) RemoveDependency(dependency string)
- func (ppm *PpmConfig) RemoveSubDependency(dependency string)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckOrCreateDir ¶
Create a certain directory if it doesn't exist
func DoesPathExist ¶
Check wether an absolute path exists
func GetPluginName ¶
func GetVersionOrNot ¶
func PlayLoadingAnim ¶
func PlayLoadingAnim(loading chan interface{})
func StringSliceContains ¶
Check wether a certain item exists in a string slice
Types ¶
type PpmConfig ¶
type PpmConfig struct {
Plugin bool `json:"plugin"`
Dependencies []string `json:"dependencies"`
SubDependencies []string `json:"sub-dependencies"`
// contains filtered or unexported fields
}
Representing a ppm.json configuration file
func ParsePpmConfig ¶
Parse the ppm.json file to an object
func (*PpmConfig) AddDependency ¶
Add an item safely to the Dependencies property
func (*PpmConfig) AddSubDependency ¶
Add an item safely to the sub-dependencies property
func (PpmConfig) HasDependency ¶
Check wether the config file has a certain dependency
func (PpmConfig) HasSubDependency ¶
Check wether the config file has a certain sub-dependency
func (PpmConfig) PrettyPrint ¶
func (ppm PpmConfig) PrettyPrint()
func (*PpmConfig) RemoveAllDependencies ¶
func (ppm *PpmConfig) RemoveAllDependencies()
Remove ALL (sub)dependencies
func (*PpmConfig) RemoveDependency ¶
Remove an item safely from the sub-dependencies property by its name
func (*PpmConfig) RemoveSubDependency ¶
Remove an item safely from the Dependencies property by its name
Click to show internal directories.
Click to hide internal directories.