Documentation ¶
Index ¶
- Variables
- func CheckAllValuesOrNone(parent string, theMap map[string]string) bool
- func GetHost(url string) string
- func GetMap(excludes []string) map[string]bool
- func ParseCronSpec(spec string) (cron.Schedule, error)
- func StatRemote(remoteURL, sshURL string, repo GenRepo) bool
- type Conf
- type Destination
- type FileLogging
- type GenRepo
- type HeartbeatConfig
- type Local
- type Logging
- type Metrics
- type PrometheusConfig
- type Repo
- type Site
- type Source
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // Red Render message with Red color. Red = color.FgRed.Render // Green Render message with Green color. Green = color.FgGreen.Render // Blue Render message with Blue color. Blue = color.FgBlue.Render // DotGitRx .git regexp. DotGitRx = regexp.MustCompile(`\.git$`) )
Functions ¶
func CheckAllValuesOrNone ¶
CheckAllValuesOrNone TODO.
Types ¶
type Conf ¶
type Conf struct { Source Source `yaml:"source"` Destination Destination `yaml:"destination"` Cron string `yaml:"cron"` Log Logging `yaml:"log"` Metrics Metrics `yaml:"metrics"` }
Conf TODO.
func (Conf) HasAllPrometheusConf ¶
HasAllPrometheusConf TODO.
type Destination ¶
type Destination struct { Gitlab []GenRepo `yaml:"gitlab"` Local []Local `yaml:"local"` Github []GenRepo `yaml:"github"` Gitea []GenRepo `yaml:"gitea"` Gogs []GenRepo `yaml:"gogs"` }
Destination TODO.
type FileLogging ¶
type FileLogging struct { Dir string `yaml:"dir"` File string `yaml:"file"` MaxAge int `yaml:"maxage"` }
FileLogging TODO.
type GenRepo ¶
type GenRepo struct { Token string `yaml:"token"` TokenFile string `yaml:"token_file"` User string `yaml:"user"` SSH bool `yaml:"ssh"` SSHKey string `yaml:"sshkey"` Username string `yaml:"username"` Password string `yaml:"password"` URL string `yaml:"url"` Exclude []string `yaml:"exclude"` ExcludeOrgs []string `yaml:"excludeorgs"` Include []string `yaml:"include"` IncludeOrgs []string `yaml:"includeorgs"` Wiki bool `yaml:"wiki"` Starred bool `yaml:"starred"` CreateOrg bool `yaml:"createorg"` }
GenRepo Generell Repo.
type HeartbeatConfig ¶
type HeartbeatConfig struct {
URLs []string `yaml:"urls"`
}
type Logging ¶
type Logging struct { Timeformat string `yaml:"timeformat"` FileLogging FileLogging `yaml:"file-logging"` }
Logging TODO.
type Metrics ¶
type Metrics struct { Prometheus PrometheusConfig `yaml:"prometheus"` Heartbeat HeartbeatConfig `yaml:"heartbeat"` }
Metrics TODO.
type PrometheusConfig ¶
type PrometheusConfig struct { ListenAddr string `yaml:"listen_addr"` Endpoint string `yaml:"endpoint"` }
PrometheusConfig TODO.
type Repo ¶
type Repo struct { Name string URL string SSHURL string Token string Defaultbranch string Origin GenRepo Owner string Hoster string }
Repo TODO.
type Source ¶
type Source struct { Gogs []GenRepo `yaml:"gogs"` Gitlab []GenRepo `yaml:"gitlab"` Github []GenRepo `yaml:"github"` Gitea []GenRepo `yaml:"gitea"` BitBucket []GenRepo `yaml:"bitbucket"` OneDev []GenRepo `yaml:"onedev"` Sourcehut []GenRepo `yaml:"sourcehut"` Any []GenRepo `yaml:"any"` }
Source TODO.
Click to show internal directories.
Click to hide internal directories.