You could use ```collect``` instead of ```partition```
```scala
val depLibs = dependencies.collect {
  case Attributed(d) if ClasspathUtilities.isArchive(d) => d
}.sorted
```