✨ Add mkflex command
This commit is contained in:
parent
72295c53cf
commit
f4497aef7e
7 changed files with 333 additions and 1 deletions
38
mkflex/models.go
Normal file
38
mkflex/models.go
Normal file
|
|
@ -0,0 +1,38 @@
|
|||
package mkflex
|
||||
|
||||
import "codeberg.org/danjones000/utils/types"
|
||||
|
||||
type Config struct {
|
||||
Templates map[string]Template `yaml:"templates"`
|
||||
Tasks map[string]any `yaml:"tasks"`
|
||||
}
|
||||
|
||||
type Template struct {
|
||||
Series []SeriesGroups `yaml:"series,omitempty"`
|
||||
Aria2 map[string]any `yaml:"aria2,omitempty"`
|
||||
ConMag map[string]any `yaml:"convert_magnet,omitempty"`
|
||||
Download string `yaml:"download,omitempty"`
|
||||
Notify map[string]any `yaml:"notify,omitempty"`
|
||||
}
|
||||
|
||||
type SeriesGroups map[string]Series
|
||||
|
||||
type Identifier string
|
||||
|
||||
const (
|
||||
Sequence Identifier = "sequence"
|
||||
Episode Identifier = "ep"
|
||||
)
|
||||
|
||||
type Series struct {
|
||||
Quality string `yaml:"quality,omitempty"`
|
||||
IdentifiedBy Identifier `yaml:"identified_by,omitempty"`
|
||||
Begin types.IntOrString `yaml:"begin,omitempty"`
|
||||
Exact bool `yaml:"exact,omitempty"`
|
||||
AlternameName []string `yaml:"alternate_name,omitempty"`
|
||||
}
|
||||
|
||||
type Aria struct {
|
||||
Path string `yaml:"path"`
|
||||
Server string `yaml:"server"`
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue