Commit Graph

4833 Commits

Author SHA1 Message Date
Dale Wijnand 0ca24b69a8 Merge pull request #3202 from eed3si9n/wip/eviction
change EvictionWarningOptions.default to include callers and transitives
2017-05-22 11:14:29 +01:00
Eugene Yokota b3850872ee update EvictionWarningSpec 2017-05-21 13:59:07 -04:00
Eugene Yokota 303ee137bd Scalariform changes 2017-05-21 13:18:53 -04:00
Eugene Yokota fa82807eee bump sbt 2017-05-21 13:18:29 -04:00
Eugene Yokota 90c102badc change EvictionWarningOptions.default
Fixes sbt/sbt#3171

change EvictionWarningOptions.default to include transitive evictions and caller info.
2017-05-21 13:18:11 -04:00
eugene yokota b9170010ef Merge pull request #3194 from dwijnand/deprecate-removed-toError
Deprecate BuildCommon's toError
2017-05-16 16:42:21 -04:00
Dale Wijnand d3fa1e06c6
Deprecate BuildCommon's toError
Removed in sbt 1
2017-05-16 10:15:09 +01:00
eugene yokota 9ecc7db8f7 Merge pull request #3179 from eed3si9n/wip/zero
[sbt 0.13] Add an alias for Global called Zero
2017-05-10 16:48:26 -04:00
Eugene Yokota e80caa20a2 Add an alias for Global called Zero
Ref sbt/sbt#3178
2017-05-07 23:36:09 -04:00
eugene yokota 762a0e72dd Merge pull request #3155 from jameskoch/bug-fix
Fixes Issue #3154 - "It is not a test" in JUnit XML reports.
2017-05-05 11:03:35 -04:00
James Koch 84fc133e16 Merge branch '0.13' into bug-fix 2017-05-03 11:54:20 -04:00
eugene yokota 87db0e1bec Merge pull request #3152 from smarter/fix/dotty-scalaBinaryVersion
Fix default scalaBinaryVersion for Dotty
2017-05-03 11:49:16 -04:00
James Koch b75b7f3bbb Merge branch '0.13' into bug-fix 2017-04-30 13:19:47 -04:00
James Koch ecf14d6ad5 Issue #3154 - ScalaTest nested suites reported in JUnit XML reports as "(It is not a test)". 2017-04-30 13:16:23 -04:00
Dale Wijnand 3ea9bbba92 Merge pull request #3153 from dwijnand/kill-enter-to-stay-in-shell
Remove the "hit [ENTER] to switch to interactive mode" feature
2017-04-28 18:07:58 +01:00
Dale Wijnand f4cc3d2938
Remove the "hit [ENTER] to switch to interactive mode" feature
In sbt 0.13.15, in addition to notifying the user about the existence of
sbt's shell, a feature was added to allow the user to switch to sbt's
shell - a more pro-active approach to just displaying a message.

Unfortunately sbt is often unintentionally invoked in shell scripts in
"interactive mode" when no interaction is expected by, for exmaple,
invoking `sbt package` instead of `sbt package < /dev/null`. In that
case hitting [ENTER] would silently trigger sbt to run its shell,
easily wrecking the script. In addition to that I was unhappy with the
implementation as it created a tight coupling between sbt's command
processing abstraction to sbt's shell command.

If you want to stay in sbt's shell after running a task like `package`
then invoke sbt like so:

    sbt package shell

Fixes #3091
2017-04-28 11:00:16 +01:00
Guillaume Martres 629a04937f Fix default scalaBinaryVersion for Dotty
Dotty is versioned as 0.*, but `CrossVersionUtil#binaryScalaVersion`
will return the full version instead of just `major.minor` for all
compiler versions < 2.10, add a special case for Dotty to avoid this.

Note: I used tabs in this commit to match the style of the surrounding code.
2017-04-28 11:45:43 +02:00
Dale Wijnand 684e78cf19 notes 2017-04-28 09:41:53 +01:00
Eugene Yokota d15c051559 notes 2017-04-27 18:41:08 -04:00
Dale Wijnand f9c0187870 Merge pull request #3147 from dwijnand/warn-less
Improvements & bug fixes to the new startup messages
2017-04-27 18:21:30 +01:00
Dale Wijnand 5b808ee38e
Notes for changes to startup messages 2017-04-27 16:38:22 +01:00
Dale Wijnand 54055835be
Notify users about shell only if compile is present
This is a change in strategy.

The motivation is the need to find a good balance between:

  + informing the uninformed that would benefit from this information, &
  + not spamming the already informed

Making it dependent on "compile" being present in remainingCommands will
probably make it trigger for, for example, Maven users who are used to
running "mvn compile" and always run "sbt compile", and who therefore
are unneccesarily suffering terribly slow compile speeds by starting up
the jvm and sbt every time.

Fixes #3091
2017-04-27 16:37:52 +01:00
Dale Wijnand 1c1be9a597
Introduce suppressSbtShellNotification
This requires moving the notification to after LoadProject, so much
later in time, sadly..

Refs #3091
2017-04-27 16:34:32 +01:00
Dale Wijnand a6af8c50c8
Notify users at info level & in 1 line
Refs #3091
2017-04-27 16:34:32 +01:00
Dale Wijnand 2ee0b3c064
Exclude "new" from startup messages
Fixes #3097
2017-04-27 16:34:27 +01:00
Dale Wijnand fdd3f56694
Allow --error to suppress warning messages
Specifically:

* Make them both commands, so they run after early commands (--error).
* Make notifyUsersAboutShell aware of "iflast shell" instead of "boot".
* Make writeSbtShell use a logger and tweak the message

Refs #3091
2017-04-27 16:32:48 +01:00
Dale Wijnand a4e0d9a932
Refactor State#process for clarity 2017-04-27 15:35:36 +01:00
Dale Wijnand 4ab11d7948 Merge pull request #3133 from eed3si9n/wip/sbtcrossbuilding
[sbt 0.13] Port sbt-cross-building's ^ and ^^ commands
2017-04-24 13:06:03 +01:00
Dale Wijnand f64ce4ede1 Merge pull request #3135 from eed3si9n/wip/plusequals
[sbt 0.13] Fix += interference with sbt-buildinfo
2017-04-23 12:39:56 +01:00
Eugene Yokota 90bda04695 Fix += interference with sbt-buildinfo
The macro pattern match was too general. This makes it tighter.

Fixes #3132
2017-04-22 22:59:33 -04:00
eugene yokota 76fe21eb0c Merge pull request #3134 from eed3si9n/wip/zipexception
[sbt 0.13] Ignore ZipException in cache
2017-04-22 13:55:45 -04:00
Eugene Yokota ff017eb475 Port sbt-cross-building's ^ and ^^ commands
This ports sbt-cross-building's cross (`^`) and switch (`^^`) commands.
Instead of making it a plugin, the default settings are now changed
to use `sbtVersion in pluginCrossBuild` for the sbt dependency.
2017-04-22 06:04:56 -04:00
Eugene Yokota 16c8da21ed Ignore ZipException in cache
Fixes #3050
2017-04-22 05:10:23 -04:00
Eugene Yokota 83581db93f Bump to 0.13.16-SNAPSHOT 2017-04-22 05:09:22 -04:00
Eugene Yokota 596702f929 0.13.15 2017-04-09 16:54:02 -04:00
eugene yokota 1fe99df985 Merge pull request #3089 from eed3si9n/wip/slash
Add three slashes (u3) for file URI
2017-04-09 08:50:10 -04:00
Eugene Yokota f42ddc8cfe Add three slashes (u3) for file URI
#3088 attemped to fix the #3086, but by putting no slashes in `sbt.boot.properties` the launcher created by 0.13.15-* becomes incompatible for all previous sbt versions.

The uglier but backward compatible fix for #3086 is to use u3 format with three slashes. This on Windows will resolve to `file:///C:/Users/foo/.sbt/preloaded`, and on Mac and Linux `file:////root/.sbt/preloaded/`. Mac and Linux are both tolerant of extra slashes on the front:

```
> eval new File(new URL("file:////Users/foo/.sbt/preloaded/").toURI)
[info] ans: java.io.File = /Users/foo/.sbt/preloaded
```
2017-04-09 03:11:38 -04:00
eugene yokota c31dfda4ba Merge pull request #3088 from eed3si9n/wip/windows_file
Improve IO.toFile for Windows
2017-04-08 12:17:39 -07:00
Eugene Yokota de3d711f06 Remove slashes from local-preloaded
On Mac and Linux, user.home should return `/home/foo`, resulting to `file:/home/foo`.

On Windows, user.home should return `C:\Users\foo`, resulting to `file:C:/Users/foo`.
2017-04-08 03:59:52 -04:00
Eugene Yokota dea267c224 Improve IO.toFile's handling for Windows
Improve IO.toFile's handling for Windows, and use it for identifying resolvers.

This adds support to convert URL to File on Windows in several ways:

```
val u0 = new URL("file:C:\\Users\\foo/.sbt/preloaded")
val u1 = new URL("file:/C:\\Users\\foo/.sbt/preloaded")
val u2 = new URL("file://unc/Users/foo/.sbt/preloaded")
val u3 = new URL("file:///C:\\Users\\foo/.sbt/preloaded")
val u4 = new URL("file:////unc/Users/foo/.sbt/preloaded")
```

Note that `u0` and `u2` are something `new File(u.toURI)` won't handle. This also correctly handles UNC convention specified by Microsoft in https://blogs.msdn.microsoft.com/ie/2006/12/06/file-uris-in-windows/.

Fixes #3086
Fixes #2150
2017-04-08 03:56:34 -04:00
Eugene Yokota 3247e69cc8 0.13.15-SNAPSHOT 2017-04-07 03:16:43 -04:00
Eugene Yokota ebf3fc0fca launchconfig 2017-04-07 03:15:09 -04:00
Eugene Yokota 54bd86f3c0 notes 2017-04-07 02:09:36 -04:00
eugene yokota ce0f558f38 Merge pull request #3035 from dwijnand/notify-less
Notify about shell less
2017-03-22 09:26:41 -07:00
Dale Wijnand bd59f14f08
Notify about shell less
+ Don't notify ScriptMain users by moving the logic to xMain
+ Only trigger shell if shell is a defined command
+ Use existing Shell/BootCommand strings instead of new ones
2017-03-21 13:20:34 +00:00
Eugene Yokota 8b74f1d9d3 0.13.14-RC2 2017-03-20 23:12:27 -04:00
Dale Wijnand 7f2bf7ce1b Merge pull request #3025 from dwijnand/sbt.version
Write sbt.version to project/build.properties
2017-03-17 09:47:41 +00:00
Dale Wijnand aaaf254375
Tell the user we're setting sbt.version 2017-03-16 21:49:15 +00:00
Dale Wijnand 465a9be635
Add -Dsbt.skip.version.write=true opt-out 2017-03-16 19:42:17 +00:00
Dale Wijnand 155f764943
Write sbt.version to project/build.properties
Have sbt.version set in project/build.properties is a best practice
because it makes the build more deterministic and reproducible.

With this change sbt, after ensuring that the base directory is probably
an sbt project, writes out sbt.version in project/build.properties if it
is missing.

Fixes #754
2017-03-16 18:55:26 +00:00