2021-05-30 23:04:17 +02:00
|
|
|
package main
|
|
|
|
|
|
|
|
// Destination
|
|
|
|
type Destination struct {
|
2021-06-01 20:04:38 +02:00
|
|
|
Gitlab []GenRepo `yaml:"gitlab"`
|
|
|
|
Local []Local `yaml:"local"`
|
|
|
|
Github []GenRepo `yaml:"github"`
|
|
|
|
Gitea []GenRepo `yaml:"gitea"`
|
|
|
|
Gogs []GenRepo `yaml:"gogs"`
|
2021-05-30 23:04:17 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
// Local
|
|
|
|
type Local struct {
|
|
|
|
Path string `yaml:"path"`
|
|
|
|
}
|
|
|
|
|
|
|
|
// Conf
|
|
|
|
type Conf struct {
|
|
|
|
Source Source `yaml:"source"`
|
|
|
|
Destination Destination `yaml:"destination"`
|
|
|
|
}
|
|
|
|
|
|
|
|
// Source
|
|
|
|
type Source struct {
|
2021-06-01 21:43:25 +02:00
|
|
|
Gogs []GenRepo `yaml:"gogs"`
|
|
|
|
Gitlab []GenRepo `yaml:"gitlab"`
|
|
|
|
Github []GenRepo `yaml:"github"`
|
|
|
|
Gitea []GenRepo `yaml:"gitea"`
|
|
|
|
BitBucket []GenRepo `yaml:"bitbucket"`
|
2021-05-30 23:04:17 +02:00
|
|
|
}
|
|
|
|
|
2021-05-31 23:11:45 +02:00
|
|
|
// Generell Repo
|
|
|
|
type GenRepo struct {
|
2021-12-03 21:34:46 +01:00
|
|
|
Token string `yaml:"token"`
|
|
|
|
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"`
|
2021-05-30 23:04:17 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
// Repo
|
|
|
|
type Repo struct {
|
|
|
|
Name string
|
|
|
|
Url string
|
2021-05-31 23:11:45 +02:00
|
|
|
SshUrl string
|
2021-05-30 23:04:17 +02:00
|
|
|
Token string
|
|
|
|
Defaultbranch string
|
2021-06-01 20:04:38 +02:00
|
|
|
Origin GenRepo
|
2021-05-30 23:04:17 +02:00
|
|
|
}
|
2021-12-03 07:34:08 +01:00
|
|
|
|
|
|
|
// Site
|
|
|
|
type Site struct {
|
|
|
|
Url string
|
|
|
|
User string
|
|
|
|
Port int
|
|
|
|
}
|