2023-04-08 13:38:25 -04:00
|
|
|
package internal
|
|
|
|
|
|
|
|
// A simple example demonstrating the use of multiple text input components
|
|
|
|
// from the Bubbles component library.
|
|
|
|
|
|
|
|
import (
|
2023-04-10 07:10:19 -04:00
|
|
|
"os"
|
|
|
|
|
2023-04-08 13:38:25 -04:00
|
|
|
"github.com/HikariKnight/ls-iommu/pkg/errorcheck"
|
2023-12-26 12:42:49 -05:00
|
|
|
"github.com/HikariKnight/quickpassthrough/internal/pages"
|
2023-04-08 13:38:25 -04:00
|
|
|
tea "github.com/charmbracelet/bubbletea"
|
|
|
|
)
|
|
|
|
|
|
|
|
// This is where we build everything
|
|
|
|
func Tui() {
|
2023-12-26 12:42:49 -05:00
|
|
|
// Log all errors to a new logfile (super useful feature of BubbleTea!)
|
2023-04-10 07:10:19 -04:00
|
|
|
os.Remove("debug.log")
|
|
|
|
logfile, err := tea.LogToFile("debug.log", "")
|
|
|
|
errorcheck.ErrorCheck(err, "Error creating log file")
|
|
|
|
defer logfile.Close()
|
|
|
|
|
2023-10-26 14:45:11 -04:00
|
|
|
// New WIP Tui
|
2023-12-26 12:42:49 -05:00
|
|
|
pages.Welcome()
|
2023-04-08 13:38:25 -04:00
|
|
|
}
|