🚧 Work on fingerprinting music

This commit is contained in:
Dan Jones 2023-09-23 21:57:56 -05:00
commit cfef5a6c7a
3 changed files with 59 additions and 2 deletions

View file

@ -21,6 +21,11 @@ func (st AppStep) Title() string {
return mustpick
}
return fmt.Sprintf("Trim and/or add fade to %s", file.ShortPath())
case Print:
if file == nil {
return mustpick
}
return fmt.Sprintf("Should we try to identify %s", file.ShortPath())
case Restart:
return "Forget current selection"
case Quit:
@ -31,6 +36,9 @@ func (st AppStep) Title() string {
}
func (st AppStep) Text() string {
if st == Print {
return "Use fpcalc, AcousticId, and MusicBrainz to identify the song"
}
return ""
}
@ -44,6 +52,8 @@ func (st AppStep) Rune() rune {
return 'f'
case Restart:
return 'r'
case Print:
return 'a'
case Quit:
return 'q'
default:
@ -60,7 +70,7 @@ func mainMenu() AppStep {
if file == nil {
steps = []list.Option{Pick, Quit}
} else {
steps = []list.Option{Pick, Watch, Fade, Quit}
steps = []list.Option{Pick, Watch, Fade, Print, Quit}
}
step := list.List("What would you like to do next?", steps, nil)