[bugfix] temporary fix, starting the routes without the tui
This commit is contained in:
parent
1aa929079f
commit
0826600ee3
12
cmd/main.go
12
cmd/main.go
@ -7,7 +7,6 @@ import (
|
||||
"log"
|
||||
"net"
|
||||
"net/http"
|
||||
"os"
|
||||
"time"
|
||||
|
||||
router "synf/internal/api/routes"
|
||||
@ -27,7 +26,7 @@ type model struct {
|
||||
selected map[int]struct{}
|
||||
}
|
||||
|
||||
func initalModel() model {
|
||||
func commands() model {
|
||||
return model{
|
||||
choices: []string{"start", "migrate", "reset-migrations"},
|
||||
selected: make(map[int]struct{}),
|
||||
@ -142,9 +141,16 @@ func RawConnect(host string, port string) {
|
||||
}
|
||||
|
||||
func main() {
|
||||
p := tea.NewProgram(initalModel())
|
||||
/*
|
||||
p := tea.NewProgram(commands())
|
||||
if _, err := p.Run(); err != nil {
|
||||
fmt.Printf("Alas, there's been an error: %v", err)
|
||||
os.Exit(1)
|
||||
}
|
||||
*/
|
||||
|
||||
PORT = ":8500"
|
||||
|
||||
r := router.InitRestRoutes()
|
||||
log.Fatal(http.ListenAndServe(PORT, r))
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user