mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-01-13 07:40:00 -06:00
Merge pull request #7288 from kobergj/FixMarkdownCreation
[docs-only] Fix Markdown creation for new services
This commit is contained in:
@@ -66,6 +66,11 @@ func generateMarkdown(filepath string, servicename string) error {
|
||||
return err
|
||||
}
|
||||
|
||||
targetFile := fmt.Sprintf("../../docs/services/%s/_index.md", servicename)
|
||||
return os.WriteFile(targetFile, b.Bytes(), os.ModePerm)
|
||||
path := fmt.Sprintf("../../docs/services/%s", servicename)
|
||||
|
||||
if err := os.Mkdir(path, os.ModePerm); err != nil && !os.IsExist(err) {
|
||||
return err
|
||||
}
|
||||
|
||||
return os.WriteFile(path+"/_index.md", b.Bytes(), os.ModePerm)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user