this repo has no description smallweb.run
smallweb
4
fork

Configure Feed

Select the types of activity you want to include in your feed.

fix deno executable check

pomdtr a2c9330a 1c28f606

+9 -4
+2 -1
cmd/doctor.go
··· 7 7 "strings" 8 8 9 9 "github.com/Masterminds/semver" 10 + "github.com/pomdtr/smallweb/worker" 10 11 "github.com/spf13/cobra" 11 12 ) 12 13 ··· 54 55 } 55 56 56 57 func checkDenoVersion() (string, error) { 57 - deno, err := exec.LookPath("deno") 58 + deno, err := worker.DenoExecutable() 58 59 if err != nil { 59 60 return "", err 60 61 }
+7 -3
cmd/up.go
··· 57 57 Aliases: []string{"serve"}, 58 58 Args: cobra.NoArgs, 59 59 PreRunE: func(cmd *cobra.Command, args []string) error { 60 - // if _, err := checkDenoVersion(); err != nil { 61 - // return err 62 - // } 60 + if _, err := checkDenoVersion(); err != nil { 61 + return err 62 + } 63 63 64 64 oldCronFlag, _ := cmd.Flags().GetBool("cron") 65 65 if oldCronFlag { ··· 69 69 return nil 70 70 }, 71 71 RunE: func(cmd *cobra.Command, args []string) error { 72 + if k.String("dir") == "" { 73 + return fmt.Errorf("dir cannot be empty") 74 + } 75 + 72 76 if k.String("domain") == "" { 73 77 return fmt.Errorf("domain cannot be empty") 74 78 }