Files
asciinema/commands/play.go

18 lines
314 B
Go
Raw Normal View History

package commands
2015-03-03 16:13:33 +01:00
import "github.com/asciinema/asciinema-cli/asciicast"
type PlayCommand struct {
Player asciicast.Player
}
2015-03-03 16:13:33 +01:00
func NewPlayCommand() *PlayCommand {
return &PlayCommand{
Player: asciicast.NewPlayer(),
}
}
2015-03-03 16:13:33 +01:00
func (c *PlayCommand) Execute(filename string) error {
return c.Player.Play(filename)
}