Scala language server using sbt


It's been a month since sbt 1.0 shipped, and I can finally sit back and think about sbt server again. Using my weekends time, I started hacking on an implementation of Scala language server on top of sbt server.




Persistent Versioning

In this post, I'd like to introduce a version scheme that I call Persistent Versioning. Most of the ideas presented in this post are not new or my own. Let me know if there's already a name for it.

In 2015, Jake Wharton (@JakeWharton) wrote a blog post titled Java Interoperability Policy for Major Version Updates:

  1. Rename the Java package to include the version number.

    This immediately solves the API compatibility problem from transitive dependencies on multiple versions. Classes from each can be loaded on the same classpath without interacting negatively.

    (Libraries with a major version of 0 or 1 can skip this, and only start with major version 2 and above.)

  2. Include the library name as part the group ID in the Maven coordinates.

    Even for projects that have only a single artifact, including the project name in the group ID allows future updates that may introduce additional artifacts to not pollute the root namespace. In projects that have multiple artifacts from inception, it provides a means of grouping them together on artifact hosts like Maven central. ....

  3. Rename the group ID in the Maven coordinates to include the version number.

    Individual group IDs prevent dependency resolution semantics to upgrade older versions to newer, incompatible ones. Each major version is resolved independently allowing transitive dependencies to be upgraded compatibly.

    (Libraries with a major version of 0 or 1 can skip this, and only start with major version 2 and above.)

In the tweet thread Jake cites RxJava's two GitHub issues Version 2.x Maven Central Identification ReactiveX/RxJava#3170 and 2.0 Package Name ReactiveX/RxJava#3173, both opened by Ben Christensen (@benjchristensen).

sbt 1.0.0 is now available

Wrote sbt 1.0.0 is now available on Tech Hub blog.

auto publish from Travis-CI


GitHub Pages is a convenient place to host OSS project docs.
This post explains how to use Travis CI to deploy your docs automatically on a pull request merge.

1. Generate a fresh RSA key in some directory

Make a directory outside of your project first.
Pick a key name deploy_yourproject_rsa, so you can distinguish it from other keys.

$ mkdir keys
$ cd keys
$ ssh-keygen -t rsa -b 4096 -C ""
Generating public/private rsa key pair.
Enter file in which to save the key (/Users/xxx/.ssh/id_rsa): deploy_website_rsa

tray for Atreus



In the last post that I wrote about Atreus build, I noted that there's an issue of keyboard positioning:

Even if I can overcome the layout and memorize the various symbol locations, there's the issue of the placement. If I place the keyboard in between me and the laptop the screen becomes too far.

I solved this issue by making a tray for Atreus that I can position it on top of the MacBook Pro keyboard.



Last night I finished making my Atreus keyboard from a DYI kit that I got a while back.
Here are some of the details:

  • I chose Matias Quiet Click switch option (gray slider). There's no clicking.
  • The modifiers use Matias Quiet Linear switches (red slider).
  • There are 42 keys in split ortholinear layout.
  • Mahogany ply case.

The materials

Gigahorse 0.3.0


Gigahorse 0.3.0 is now released. See documentation on what it is.

OkHttp support

0.3.0 adds Square OkHttp support. Gigahorse-OkHttp is availble for Scala 2.10, 2.11, and 2.12.

According to the JavaDoc you actually don't have to close the OkHttpClient instance.

scala> import gigahorse._, support.okhttp.Gigahorse
import gigahorse._
import support.okhttp.Gigahorse
scala> import scala.concurrent._, duration._
import scala.concurrent._
import duration._

sbt 1.0 roadmap and beta-1


Wrote sbt 1.0 roadmap and beta-1 on Tech Hub blog.

downloading and running app on the side with sbt-sidedish


I've been asked by a few people on downloading JARs, and then running them from an sbt plugin.
Most recently, Shane Delmore (@shanedelmore) asked me about this at nescala in Brooklyn.

During an unconference session I hacked together a demo, and I continued some more after I came home.


herding cats: day 16

Syndicate content