Allow setting metadata directory from UI (#1782)

This commit is contained in:
WithoutPants
2021-10-03 11:35:30 +11:00
committed by GitHub
parent 52193586de
commit 7464454da5
7 changed files with 43 additions and 0 deletions

View File

@@ -61,6 +61,15 @@ func (r *mutationResolver) ConfigureGeneral(ctx context.Context, input models.Co
c.Set(config.Generated, input.GeneratedPath)
}
if input.MetadataPath != nil {
if *input.MetadataPath != "" {
if err := utils.EnsureDir(*input.MetadataPath); err != nil {
return makeConfigGeneralResult(), err
}
}
c.Set(config.Metadata, input.MetadataPath)
}
if input.CachePath != nil {
if *input.CachePath != "" {
if err := utils.EnsureDir(*input.CachePath); err != nil {