Skip to content

Commit

Permalink
Don't create build folder and remove it right before renaming .tmp fo…
Browse files Browse the repository at this point in the history
…lder. Fix #2
  • Loading branch information
stirante committed Aug 5, 2021
1 parent 5f2ae40 commit d936350
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions src/filters.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,6 @@ func Setup() error {
if err != nil {
return err
}
err = os.RemoveAll("build")
if err != nil {
return err
}
err = os.Mkdir("build", 777)
if err != nil {
return err
}
err = os.Mkdir(".tmp", 777)
if err != nil {
return err
Expand Down Expand Up @@ -61,6 +53,7 @@ func RunProfile(profileName string) {
//copy contents of .tmp to build
Logger.Info("Moving files to target directory")
start := time.Now()
os.RemoveAll("build")
os.Rename(".tmp", "build")
Logger.Debug("Done in ", time.Since(start))
//Done!
Expand Down

0 comments on commit d936350

Please sign in to comment.