Fix: cleanup

This commit is contained in:
[BOT] pages deployer 2023-08-25 23:41:25 +02:00
parent 2f5528a63e
commit c63c30fa47
No known key found for this signature in database
GPG key ID: 989DE36109AFA354

View file

@ -134,6 +134,10 @@ func writeConfig(args Args) error {
} }
func copyFiles(args Args) error { func copyFiles(args Args) error {
if err := os.RemoveAll("/tmp/pages"); err != nil {
return err
}
if err := os.MkdirAll("/tmp", 777); err != nil { if err := os.MkdirAll("/tmp", 777); err != nil {
return err return err
} }
@ -152,6 +156,10 @@ func copyFiles(args Args) error {
return err return err
} }
if err := os.RemoveAll("/tmp/pages/.git"); err != nil {
return err
}
return os.Chdir("/tmp/pages") return os.Chdir("/tmp/pages")
} }