🚧 Ask for next step

This commit is contained in:
Dan Jones 2023-09-06 18:46:09 -05:00
commit 5472d7376a
5 changed files with 26 additions and 11 deletions

View file

@ -4,6 +4,7 @@ import (
"fmt"
"os"
"codeberg.org/danjones000/strip-beats/input/boolean"
"codeberg.org/danjones000/strip-beats/media"
)
@ -31,11 +32,15 @@ func Run(step AppStep) {
if file == nil {
quit()
}
watch := boolean.Choose(fmt.Sprintf("Would you like to watch %s?", file.ShortPath()))
if watch {
step = Watch
}
case Watch:
media.Watch(file.Format.Path)
step = Quit // @todo
case Quit:
quit()
}
step = (step + 1) % Restart
}
}