Added github branch fetching

This commit is contained in:
2026-03-30 21:13:50 +02:00
parent a8a2b3f95a
commit e81286b394
6 changed files with 272 additions and 9 deletions
+1 -4
View File
@@ -7,7 +7,6 @@ import (
)
type GlobalConfig struct {
Token string `yaml:"token"`
GithubPat string `yaml:"github_pat"`
StoragePath string `yaml:"storage_path"`
}
@@ -20,6 +19,7 @@ type SiteConfig struct {
Domain string `yaml:"domain"`
SPA bool `yaml:"spa"`
NotFoundFile string `yaml:"not_found_file"`
DeployToken string `yaml:"deploy_token"`
}
type Config struct {
@@ -37,9 +37,6 @@ func (c Error) Error() string {
}
func validateConfig(config *Config) error {
if config.Global.Token == "" {
return &Error{Field: "global.token", Message: "Token is required"}
}
if config.Global.GithubPat == "" {
return &Error{Field: "global.github_pat", Message: "GitHub PAT is required"}
}