Skip to content

Commit

Permalink
fix: create empty snippet folder for 6.6.3.0 to not crash the admin
Browse files Browse the repository at this point in the history
  • Loading branch information
shyim committed Jun 6, 2024
1 parent 2ba0c87 commit 9eb3c3b
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions cmd/project/ci.go
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,10 @@ var projectCI = &cobra.Command{
return err
}

if err := createEmptySnippetFolder(path.Join(args[0], "vendor", "shopware", "administration")); err != nil {
return err
}

if !shopCfg.Build.KeepExtensionSource {
for _, source := range sources {
if err := cleanupAdministrationFiles(cmd.Context(), source.Path); err != nil {
Expand Down Expand Up @@ -205,6 +209,14 @@ var projectCI = &cobra.Command{
},
}

func createEmptySnippetFolder(root string) error {
if _, err := os.Stat(path.Join(root, "Resources/app/administration/src/module")); os.IsNotExist(err) {
return os.MkdirAll(path.Join(root, "Resources/app/administration/src/module"), os.ModePerm)
}

return nil
}

type ComposerAuth struct {
HTTPBasicAuth *interface{} `json:"http-basic,omitempty"`
BearerAuth map[string]string `json:"bearer,omitempty"`
Expand Down

0 comments on commit 9eb3c3b

Please sign in to comment.