Commit Graph

17940 Commits

Author SHA1 Message Date
Alexandre Archambault 3e270c9fb2 Add new DEVELOPMENT.md file
Consisting mainly of a cookbook of sbt commands to be used during development.
2017-10-24 14:39:30 +02:00
Dale Wijnand e0d8079083
Scalafmt 1.3, sbt-scalafmt 1.14 2017-10-24 12:23:37 +01:00
Dale Wijnand 78c5ee92d3
Track sources in base directory non-recursively
Using a recursive Source meant that ~ looked into target. If you have
any source generators and use ~ with anything the invokes them, like
~compile, that means that the act of generating sources triggers ~ to
re-execute compile (perhaps only on macOS where the NIO WatchService
just polls, after an initial delay).

Requires sbt/io#78

Fixes #3501
2017-10-24 11:09:00 +01:00
Eugene Yokota dcdbcd4979 Bump Ivy to 2.3.0-sbt-1b57d3bbc08ecf671169fd548918da18c91f77be
Ref https://github.com/sbt/ivy/pull/26
Ref sbt/launcher#38

JDK 9 complains when java.lang.reflect.Field#setAccessible is called. So on
JDK 9 to get the default Authenticator on JDK you can just call
Authenticator.getDefault(). However ivy targets JDK 6..

So on JDK < 9 we do what we've always done, and on JDK 9+ we use java
reflection to call Authenticator.getDefault(), which is public and doesn't
require setAccessible(true).
2017-10-24 03:16:17 -04:00
Johannes Rudolph f82df10711 Fix compilation warnings 2017-10-23 17:35:30 +02:00
Johannes Rudolph 68bc4f53cf Fix sbt-test issues 2017-10-23 17:35:14 +02:00
Johannes Rudolph a66dabcc3b Make ignoreMissingUpdate work again for both sbt 0.13 and 1.0 2017-10-23 17:24:49 +02:00
Johannes Rudolph d3676dd17f Fix configuration usage for sbt 0.13 2017-10-23 16:53:00 +02:00
Johannes Rudolph 73faf777f2 Make autoconversion from sbinary -> jsonnew only apply in sbt 1.x 2017-10-23 16:52:38 +02:00
Johannes Rudolph e813b28a1c Move SbtAccess to our own package below sbt to prevent accidental namespace clashes with other plugins / sbt 2017-10-23 16:44:15 +02:00
Johannes Rudolph cfa9f462cf Test for all sbt versions on travis 2017-10-23 16:26:43 +02:00
Johannes Rudolph 0bbeea3977 Modernize and adapt build, update to newest versions 2017-10-23 16:26:43 +02:00
Johannes Rudolph 8d5e9d9015 Cleanup README 2017-10-23 16:14:18 +02:00
Allan Timothy Leong bd1a38be54 Remove unused imports + variables 2017-10-22 16:31:03 +08:00
Eugene Yokota bcd21ba9b6 Merge branch 'wip/3648' into 1.x 2017-10-20 23:58:39 -05:00
Alexandre Archambault 3636c58d07 Workaround issue with JAR list in pack directories
With just `sbt cli/pack`, it seems that the JARs of the other projects also
land in the pack directory. A `sbt "project cli" pack` works fine
though.
2017-10-21 02:50:08 +02:00
Alexandre Archambault 5f5b127563 Bump dependencies 2017-10-21 02:30:51 +02:00
Alexandre Archambault ce2a01af40 Bump plugins 2017-10-21 01:53:25 +02:00
eugene yokota 294a12fbf1 Merge pull request #3654 from scalacenter/json-locks
Add vscode-sbt-scala json locks
2017-10-20 17:19:45 -05:00
jvican 41a058c9b9
Add vscode-sbt-scala json locks
This is what gets generated after `compile`.
2017-10-20 20:05:16 +02:00
Dale Wijnand 9e85c08fb1 Merge pull request #3651 from eed3si9n/wip/scala2124
Bump to Scala 2.12.4
2017-10-20 06:44:09 -05:00
Eugene Yokota ae860d5a7d Bump to Scala 2.12.4
Uses Scala 2.12.4 for the build definition. This includes fix for runtime reflection of empty package members under Java 9.

Fixes sbt/sbt#3587
2017-10-20 00:23:29 -05:00
Alexandre Archambault 5645f8fe6d Remove scoverage
It was unused for now, it may be added back later
2017-10-20 02:48:11 +02:00
Yi Cheng 07e985bffc Fix cli print out completeness and cyclic handling issue (#671)
* simplify

* doc

* rename

* char

* more tests

* add tests then fix bugs

* Small tweak to avoid quadratic calculation
2017-10-20 00:54:58 +02:00
Simon Schäfer ebac491501 Disable patvars warnings
There are simply too many unused pattern vars and I don't want to fix
them right now. And watching all of the warnings everywhere is annoying.
2017-10-19 13:07:24 +02:00
Simon Schäfer 93e08b7ee7 Fix warnings about unused pattern vars in various projects 2017-10-19 13:07:24 +02:00
Simon Schäfer 187a861194 Fix unused pattern match vals in run project 2017-10-19 13:07:24 +02:00
Simon Schäfer ede94cb34c Fix unused pattern vals warnings in main-command project 2017-10-19 13:07:24 +02:00
Simon Schäfer 0454b873bf Fix warnings in protocol project
There were warnings about catch all exception handlers.
2017-10-19 13:07:24 +02:00
Simon Schäfer dc5411836a Fix warnings in util-copmlete project
There were warnings because of
- unused pattern match values
- deprecations
- unused methods (`def unary_-` and `def -`)
2017-10-19 13:07:24 +02:00
Simon Schäfer 38f550deef Fix warnings in util-collection project
There were warnings because of
- unused pattern match values
- deprecations
- a Xlint bug in scalac
2017-10-19 13:07:24 +02:00
Simon Schäfer 30d59d356d Disable warnings for unused params and implicits
There are many warnings because unused parameter are everywhere.
2017-10-19 13:07:24 +02:00
Guillaume Massé 66f801bf92 Compiles with sbt 1.0 and sbt 0.13
1. ascii-graphs

We need a 2.12 version of ascii-graphs. The last commit to the project is in June 2013 (https://github.com/mdr/ascii-graphs/graphs/contributors). We are now in October 2017. I opened a PR (https://github.com/mdr/ascii-graphs/pull/11) but I don't expect any progress on this front. We can maintain a fork or drop ascii-graphs.

2. ignoreMissingUpdate

ignoreMissingUpdate is a tricky one. Here is some explanation:

we need to duplicate the updateTask

in sbt it's define as:

```scala
def updateTask: Initialize[Task[UpdateReport]] = Def.task {
  // ...
  val uc0 = updateConfiguration.value
  // ...
}
```

since it's not scoped to our task (ex: `updateConfiguration in ignoreMissingUpdate`) we cannot just do

```scala
updateConfiguration in ignoreMissingUpdate := {
  updateConfiguration.value.withMissingOk(true)
}
```

For example, the following example yield `"u2: false"

```
val update2 = TaskKey[Unit]("update2", "...")
val update2Configuration = SettingKey[Boolean]("...")

update2 := Def.task {
  val u2 = (update2Configuration in update2).value
  println(s"u2: $u2")
}.value

update2Configuration := false
update2Configuration in update2 := true
```

3. cross publishing

We can use the ^ operator to publish. For example: `sbt "^ publish"` to publish for both sbt 0.13 and 1.0.
2017-10-17 15:42:00 +02:00
Greg Dorrell 3d47b63d21 Update homebrew installation command (#672)
* Update homebrew installation command

The command to install via homebrew didn't work for me. Presumably this changed in a recent version of homebrew.

This is the error I received:
```
$ brew install coursier/formulas/coursier

Error: coursier/formulas/coursier is a head-only formula
Install with `brew install --HEAD coursier/formulas/coursier`
```

So this change just incorporates the fix it suggests, which works for me.

* Fix other brew command, and report things to doc/README.md
2017-10-17 12:52:37 +02:00
Guillaume Massé 8591a5adae Bump to sbt 0.13.16, drop support for sbt 0.12.x 2017-10-16 16:44:26 +02:00
eugene yokota c48047850a Merge pull request #173 from dwijnand/reflect-on-jdk9
On JDK 9 call java.net.Authenticator.getDefault
2017-10-13 21:17:07 -04:00
eugene yokota 91b56c50db Merge pull request #174 from sbt/string-interp
Add a missing string interp
2017-10-13 21:11:28 -04:00
Dale Wijnand 4ce4fb72bd Merge pull request #3635 from PanAeon/escape-sbt-file-imports
Escape imports from sbt files
2017-10-13 16:17:21 +01:00
Dale Wijnand fd0d538511
On JDK 9 call java.net.Authenticator.getDefault
JDK 9 complains when java.lang.reflect.Field#setAccessible is called.
So on JDK 9 to get the default Authenticator on JDK you can just call
Authenticator.getDefault(). However lm targets JDK 8..

So on JDK 8 we do what we've always done, and on JDK 9 we use java
reflection to call Authenticator.getDefault(), which is public and
doesn't require setAccessible(true).

Fixes #169
2017-10-13 15:16:08 +01:00
Dale Wijnand 340b4ab9ec Add a missing string interp
Fixes sbt/sbt#3637
2017-10-13 15:00:38 +01:00
PanAeon 64241e0d3a Fixes #3464. Escape imports from sbt files, so if user creates a backquoted definition then task evalution will not fail. 2017-10-13 11:04:15 +01:00
Dale Wijnand 86be5359e7
Initial scaladoc Initialize/Keyed/KeyedInitialize 2017-10-12 20:31:25 +01:00
Dale Wijnand 10397926aa
Make sure of EvaluateTask in Extracted obvious 2017-10-12 15:36:05 +01:00
eugene yokota fa33b6e422 Merge pull request #3632 from dwijnand/trailing-println
Kill trailing println
2017-10-11 13:38:09 -04:00
Dale Wijnand d8e52bb5d4
Kill trailing println 2017-10-11 15:29:15 +01:00
eugene yokota fd20d3039a Merge pull request #3629 from sbt/1.0.x
Merge 1.0.x
2017-10-10 12:32:10 -04:00
eugene yokota 8c04b267bf Merge branch '1.x' into 1.0.x 2017-10-10 10:57:05 -04:00
Dale Wijnand 85af599b52 Merge pull request #3626 from eed3si9n/bport/3597
[1.0.x] Add system property to revert to old polling fs watcher
2017-10-10 11:36:13 +01:00
Michael Stringer b9a4d32916 Add system property to revert to old polling fs watcher
This adds a sbt.watch.mode system property that if set to 'polling' will
use PollingWatchService instead of WatchServiceAdapter (nio).

On macOS this will default to 'polling' and on all others 'nio'.

This is a temporary workaround for users affected by #3527
2017-10-10 01:17:42 -04:00
eugene yokota 8da85e9380 Merge pull request #3597 from sbt/workaround/3527
Add system property to revert to old polling fs watcher
2017-10-10 01:14:03 -04:00