🚸 Add main menu

This commit is contained in:
Dan Jones 2023-09-08 11:00:07 -05:00
commit d8e671d5ca
4 changed files with 83 additions and 28 deletions

View file

@ -8,7 +8,6 @@ import (
"os"
"codeberg.org/danjones000/strip-beats/app"
// "codeberg.org/danjones000/strip-beats/input/list"
"github.com/spf13/cobra"
)
@ -20,28 +19,6 @@ var rootCmd = &cobra.Command{
// has an action associated with it:
Run: func(cmd *cobra.Command, args []string) {
app.Run(0)
/*
opt := list.List([]list.Option{
list.SimpleItem("Yes", "", 'y'),
list.SimpleItem("No", "", 'n'),
list.SimpleItem("Maybe", "perhaps", 'm'),
}, nil)
fmt.Printf("%+v\n", opt)
// out := app.PickFileWithConf()
out := app.SetFile("/home/drj/nothing.mkv")
fmt.Println("first", out.Format.Path)
// tmp, _ := os.CreateTemp("", "audio.*.mka")
// defer os.Remove(tmp.Name())
// fmt.Println("temp", tmp.Name())
app.Finish()
fmt.Printf("%+v\n", out)
// media.Watch(out.Format.Path)
show := boolean.Choose("Show stream?")
if show {
stream := out.WantedAudioStream()
fmt.Printf("Stream %d of %s: %+v\n", stream.Index, out.Format.Path, stream)
}
*/
},
}