summaryrefslogtreecommitdiff
path: root/cmd/skiff/main.go
diff options
context:
space:
mode:
Diffstat (limited to 'cmd/skiff/main.go')
-rw-r--r--cmd/skiff/main.go6
1 files changed, 2 insertions, 4 deletions
diff --git a/cmd/skiff/main.go b/cmd/skiff/main.go
index e709227..33aaf5e 100644
--- a/cmd/skiff/main.go
+++ b/cmd/skiff/main.go
@@ -7,7 +7,6 @@ import (
"flag"
"fmt"
"os"
- "path/filepath"
"strings"
"skiff/internal/appmeta"
@@ -90,7 +89,7 @@ func cmdNewApp(args []string) error {
return fmt.Errorf("clone base dataset: %w", err)
}
- if err := os.MkdirAll(filepath.Join(cfg.AppDir(*name), "releases"), 0755); err != nil {
+ if err := os.MkdirAll(cfg.ReleasesDir(*name), 0755); err != nil {
return fmt.Errorf("create app dir: %w", err)
}
@@ -115,8 +114,7 @@ func cmdNewApp(args []string) error {
if err != nil {
return err
}
- hookPath := filepath.Join(cfg.RepoPath(*name), "hooks", "post-receive")
- if err := os.WriteFile(hookPath, []byte(hook), 0755); err != nil {
+ if err := os.WriteFile(cfg.PostReceiveHookPath(*name), []byte(hook), 0755); err != nil {
return fmt.Errorf("install post-receive hook: %w", err)
}