Skip to content

Commit

Permalink
fix -e
Browse files Browse the repository at this point in the history
  • Loading branch information
abs3nt committed Mar 2, 2023
1 parent 830dc22 commit e31ecad
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -431,13 +431,15 @@ func NewMigration(cmd *cobra.Command, args []string) {
}

cmd := exec.Command("sh", "-c", fmt.Sprintf("%s '%s'", editor, mPath))
err := cmd.Start()
cmd.Stdin = os.Stdin
cmd.Stdout = os.Stdout
cmd.Stderr = os.Stderr
err := cmd.Run()
if err != nil {
fmt.Fprintln(os.Stderr, "Failed to start editor:", err)
os.Exit(1)
}
}

}

func loadConfigAndConnectToDB(ctx context.Context) (*Config, *pgx.Conn) {
Expand Down Expand Up @@ -676,7 +678,6 @@ func SnapshotCode(cmd *cobra.Command, args []string) {
fmt.Fprintln(os.Stderr, err)
os.Exit(1)
}

}

func Status(cmd *cobra.Command, args []string) {
Expand Down

0 comments on commit e31ecad

Please sign in to comment.