Slide 1

Slide 1 text

sbt-ugli er Lightning Talk @ ScalaMatsuri 2018 After party

Slide 2

Slide 2 text

About Me Haruki Okada twitter/github: @ocadaruma Scala/Java developer

Slide 3

Slide 3 text

What is sbt-ugli er ? https://github.com/ocadaruma/sbt-ugli er ≠ sbt-uglify Ugli es Scala sources

Slide 4

Slide 4 text

Use cases ?

Slide 5

Slide 5 text

How does it work ? Surround each Scala source with package block Replace newline with whitespace/semicolon Concat all sources

Slide 6

Slide 6 text

Example Try to uglify scala-csv https://github.com/tototoshi/scala-csv addSbtPlugin("com.mayreh" % "sbt-uglifier" % "1.0") $ sbt > uglify

Slide 7

Slide 7 text

Result

Slide 8

Slide 8 text

Result > test [info] All tests passed. [info] Passed: Total 60, Failed 0, Errors 0, Passed 60

Slide 9

Slide 9 text

Example Try to uglify nscala-time https://github.com/nscala-time/nscala-time $ sbt > uglify > test [info] Failed: Total 21, Failed 0, Errors 18, Passed 3 Exception: java.lang.NoSuchMethodError: com.github.nscala_time. ...

Slide 10

Slide 10 text

Example Seems a bug of Scala https://github.com/scala/bug/issues/10783

Slide 11

Slide 11 text

Conclusion Let's write a joke plugin and report issues