Fix whitespace errors
This commit is contained in:
parent
f955a7563c
commit
afa854c55d
2
build.sc
2
build.sc
|
@ -3,6 +3,8 @@ import $ivy.`com.lihaoyi::mill-contrib-bloop:0.9.5`
|
||||||
|
|
||||||
object copret extends ScalaModule with PublishModule {
|
object copret extends ScalaModule with PublishModule {
|
||||||
def scalaVersion = "3.1.0"
|
def scalaVersion = "3.1.0"
|
||||||
|
override def ammoniteVersion = "2.5.3"
|
||||||
|
|
||||||
|
|
||||||
def publishVersion = "0.0.1"
|
def publishVersion = "0.0.1"
|
||||||
def pomSettings = PomSettings(
|
def pomSettings = PomSettings(
|
||||||
|
|
|
@ -15,12 +15,13 @@ case class Presentation(slides: Vector[Slide], meta: Map[String, String] = Map.e
|
||||||
action match
|
action match
|
||||||
case Start =>
|
case Start =>
|
||||||
executeSlide(p, pos)()
|
executeSlide(p, pos)()
|
||||||
rec(p, 1, waitkey)
|
rec(p, 0, waitkey)
|
||||||
case Next | Other(_) =>
|
case Next | Other(_) =>
|
||||||
if pos + 1 < p.slides.size then
|
if pos + 1 < p.slides.size then
|
||||||
executeSlide(p, pos + 1)()
|
executeSlide(p, pos + 1)()
|
||||||
rec(p, pos + 1, waitkey)
|
rec(p, pos + 1, waitkey)
|
||||||
else rec(p, pos, waitkey)
|
else
|
||||||
|
rec(p, pos, waitkey)
|
||||||
case QuickNext =>
|
case QuickNext =>
|
||||||
if pos + 1 < p.slides.size then
|
if pos + 1 < p.slides.size then
|
||||||
executeQuick(p, pos + 1)()
|
executeQuick(p, pos + 1)()
|
||||||
|
@ -30,7 +31,8 @@ case class Presentation(slides: Vector[Slide], meta: Map[String, String] = Map.e
|
||||||
if pos > 0 then
|
if pos > 0 then
|
||||||
executeQuick(p, pos - 1)()
|
executeQuick(p, pos - 1)()
|
||||||
rec(p, pos - 1, waitkey)
|
rec(p, pos - 1, waitkey)
|
||||||
else rec(p, pos, waitkey)
|
else
|
||||||
|
rec(p, pos, waitkey)
|
||||||
case Interactive(cmd, path) =>
|
case Interactive(cmd, path) =>
|
||||||
%(cmd)(path)
|
%(cmd)(path)
|
||||||
rec(p, pos - 1, QuickNext)
|
rec(p, pos - 1, QuickNext)
|
||||||
|
@ -47,7 +49,8 @@ case class Presentation(slides: Vector[Slide], meta: Map[String, String] = Map.e
|
||||||
target match
|
target match
|
||||||
case Some(i) => rec(p, pos, Goto(i))
|
case Some(i) => rec(p, pos, Goto(i))
|
||||||
case None => rec(p, pos - 1, QuickNext)
|
case None => rec(p, pos - 1, QuickNext)
|
||||||
case Quit => ()
|
case Quit =>
|
||||||
|
()
|
||||||
rec(this, 0, Start)
|
rec(this, 0, Start)
|
||||||
|
|
||||||
|
|
||||||
|
@ -112,9 +115,9 @@ case class TypedCommand[T](exec: T => String, display: String, cmd: T) extends S
|
||||||
def force() = _output
|
def force() = _output
|
||||||
|
|
||||||
private def typeCmd() =
|
private def typeCmd() =
|
||||||
for char <- display
|
for char <- display do
|
||||||
do print(char)
|
print(char)
|
||||||
Thread.sleep(50 + scala.util.Random.nextInt(80))
|
Thread.sleep(50 + scala.util.Random.nextInt(80))
|
||||||
println()
|
println()
|
||||||
|
|
||||||
/* Conditionally disable execution. Useful for e.g. a debug mode, or a non-interactive mode */
|
/* Conditionally disable execution. Useful for e.g. a debug mode, or a non-interactive mode */
|
||||||
|
|
|
@ -67,5 +67,4 @@ private[copret] trait TerminalSyntax:
|
||||||
def rows = jterm.getSize.getRows
|
def rows = jterm.getSize.getRows
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* vim:set tw=120: */
|
/* vim:set tw=120: */
|
||||||
|
|
Loading…
Reference in a new issue