
* Fix: don't need sudo if we're root + other aesthetics
* Heavy refactoring, see PR #28
* Fix: avoid silent fatalities
demo: https://tcp.ac/i/JMSUc.gif
* Fix: Inverse check on `IsRoot`
* D.R.Y: check for permissions error in `common.ErrorCheck`
Reduce cognitive complexity.
* Fix: Issue with copying
* Resolve https://github.com/HikariKnight/quickpassthrough/pull/28#discussion_r1646535918
* Resolve https://github.com/HikariKnight/quickpassthrough/pull/28#discussion_r1646606680 and https://github.com/HikariKnight/quickpassthrough/pull/28#discussion_r1646594105
* Revert "Resolve https://github.com/HikariKnight/quickpassthrough/pull/28#discussion_r1646606680 and https://github.com/HikariKnight/quickpassthrough/pull/28#discussion_r1646594105"
This reverts commit ce15213009
.
* Resolve https://github.com/HikariKnight/quickpassthrough/pull/28#discussion_r1646730751
25 lines
692 B
Go
25 lines
692 B
Go
package internal
|
|
|
|
// A simple example demonstrating the use of multiple text input components
|
|
// from the Bubbles component library.
|
|
|
|
import (
|
|
"os"
|
|
|
|
tea "github.com/charmbracelet/bubbletea"
|
|
|
|
"github.com/HikariKnight/quickpassthrough/internal/common"
|
|
"github.com/HikariKnight/quickpassthrough/internal/pages"
|
|
)
|
|
|
|
// This is where we build everything
|
|
func Tui() {
|
|
// Log all errors to a new logfile (super useful feature of BubbleTea!)
|
|
_ = os.Rename("quickpassthrough_debug.log", "quickpassthrough_debug_old.log")
|
|
logfile, err := tea.LogToFile("quickpassthrough_debug.log", "")
|
|
common.ErrorCheck(err, "Error creating log file")
|
|
defer logfile.Close()
|
|
|
|
// New WIP Tui
|
|
pages.Welcome()
|
|
}
|