Commit Graph

5867 Commits

Author SHA1 Message Date
eugene yokota a28381e93a
Merge pull request #3837 from eed3si9n/wip/windows2
Add Library interface
2017-12-22 16:56:03 -05:00
Eugene Yokota 0aebb92ef5 don't block the build when server can't get up 2017-12-22 16:14:05 -05:00
Eugene Yokota 0a3900f53d Add Library interface
Fixes #3821

Initially I missed why #3821 was failing.

Looking at it again, the error message reads:

```
Caused by: java.lang.IllegalArgumentException: Interface (NGWin32NamedPipeLibrary) of library=kernel32 does not extend Library
        at com.sun.jna.Native.loadLibrary(Native.java:566)
        at sbt.internal.NGWin32NamedPipeLibrary.<clinit>(NGWin32NamedPipeLibrary.java:38)
        ... 7 more
```

Inside `Native.loadLibrary`, it requires the "library" interface to extend `com.sun.jna.Library`, which this adds.
2017-12-22 16:10:46 -05:00
eugene yokota 22b7518d5d
Merge pull request #3822 from cunei/wip-milliBis
Use IO.getModifiedTimeOrZero(file) calls
2017-12-22 13:03:55 -05:00
Eugene Yokota 7f0ff7c90a IO 1.1.3, Zinc 1.1.0-RC4 2017-12-22 11:45:31 -05:00
Antonio Cunei 94e36a14c8 Change modifiedTime definitions 2017-12-22 01:55:37 +01:00
Antonio Cunei ebff7919e9 Revert *ModifiedTime() calls to *lastModified*() calls
There are just too many instances in which sbt's code relies on
the `lastModified`/`setLastModified` semantics, so instead of moving
to `get`/`setModifiedTime`, we use new IO calls that offer the new
timestamp precision, but retain the old semantics.
2017-12-22 01:55:37 +01:00
Dale Wijnand bef5c9c996
Merge pull request #3833 from eed3si9n/wip/jna
try to set jna.nosys to true programmatically
2017-12-21 08:24:17 +00:00
Eugene Yokota 13e1862c2f set jna.nosys to true programmatically
Previously I was seeing the error upon the first scripted test. I thought it was because Main was somehow not early enough. It might just be because scripted technically runs as part of the build.

Ref sbt/io#110
2017-12-21 00:08:56 -05:00
Eugene Yokota d8609ced7f formatting 2017-12-20 22:36:07 -05:00
eugene yokota eace6c0aed
Merge pull request #3828 from eed3si9n/wip/double_server
warn about multiple instances once
2017-12-20 15:38:40 -05:00
Eugene Yokota 06ffb4f440 warn about multiple instance once
Fixes #3823

When you launch a second instance of sbt on a build, prior to this change it was displaying `java.io.IOException: sbt server is already running` on every command. This make it a bit less aggressive, and just display a warning once.

```
[warn] Is another instance of sbt is running on this build?
[warn] Running multiple instances is unsupported
```
2017-12-20 10:09:03 -05:00
Eugene Yokota 4c3b770b27 bump to sbt 1.0.4 2017-12-19 20:57:09 -05:00
Dale Wijnand 257712c052
Merge pull request #3824 from eed3si9n/wip/windows
Add Windows testing
2017-12-19 17:01:13 +00:00
Dale Wijnand eed3d21c86
Merge pull request #3825 from dwijnand/houserules
Upgrade to sbt-houserules 0.3.5
2017-12-19 16:51:21 +00:00
Dale Wijnand ad2d71cae4
Upgrade to sbt-houserules 0.3.5 2017-12-19 13:25:58 +00:00
Eugene Yokota bc4d3d5031 just scripted actions/* 2017-12-19 03:24:51 -05:00
Eugene Yokota 3507403a36 -Djna.nosys=true 2017-12-19 02:46:46 -05:00
Eugene Yokota 294110e2b8 Remove JNA from sbt/sbt
There's a conflict in JNA version difference between sbt and IO.

Fixes #3821
2017-12-19 00:44:31 -05:00
Eugene Yokota c920919c2c Fix build so it works on Windows 2017-12-19 00:17:46 -05:00
Eugene Yokota ec5bdc2381 Add Windows testing 2017-12-18 23:24:20 -05:00
eugene yokota db2c54d11d
Merge pull request #3817 from eed3si9n/wip/notes
notes
2017-12-16 19:17:07 -05:00
Eugene Yokota 87bb0f48a6 notes 2017-12-16 19:16:22 -05:00
eugene yokota e40ab026c0
Merge pull request #3816 from eed3si9n/wip/bump
Convert lastModified() calls to the more precise getModifiedTime() + modules bump
2017-12-16 13:19:02 -05:00
Eugene Yokota 40b86ae412 bump modules and plugins 2017-12-16 12:22:42 -05:00
Dale Wijnand ae99922101 Use IO.getModified over importing the method 2017-12-16 12:22:42 -05:00
Antonio Cunei 46d6b01f79 Use copyLastModified() in Sync.scala
It turns out the code in Sync.scala activiely tries to transfer
the invalid modifed time of non-existent files in the source
directory over the time of the target file, which may or may
not exist. In case it exists, the modification time is set
to January 1, 1970. This is arguably a bug in Sync, which
should be adjusted to better handle mappings with source
files that do not exist. For now, however, we preserve the
current behavior, using the deprecated copyLastModified().
2017-12-16 12:22:42 -05:00
Antonio Cunei 295bcff851 Hash calculation may throw exception w/ getModifiedTime(); fix
In Eval there is a calculation of hashes by scanning the elements
of classpath, and getting the last modification time of each
directory. When lastModified() was in use, non-existent elements
would return 0L, but getModifiedTime() will throw an exception
instead (like getLastModifiedTime(), incidentally).
So, we catch the FileNotFoundException and return 0L now as well.
2017-12-16 12:22:42 -05:00
Antonio Cunei 2129f8ceb5 Use IO.copyModifiedTime() in place of IO.copyLastModified() 2017-12-16 12:22:42 -05:00
Antonio Cunei 8c7b781d3f Moved Milli._ to IO. 2017-12-16 12:22:42 -05:00
Antonio Cunei 699b53262a Convert lastModified() to sbt.io.Milli.getModifiedTime(), more precise 2017-12-16 12:22:42 -05:00
eugene yokota 487d94d856
Merge pull request #3814 from dwijnand/avoid-log4j2-error-warning
Make CaffeineCache a lazy val
2017-12-15 08:16:11 -05:00
Dale Wijnand 8bd522511d
Make CaffeineCache a lazy val
This is to avoid it initialising Log4J2 (via SLF4J), which we initialise
ourselves programmatically in LogExchange. Also there's no need to
removeAll in initialState.

Fixes #3787
2017-12-15 08:55:55 +00:00
Antonio Cunei ab2dfc7ec5 Restore test run/error
This reverts commit 4ac231dd49.
2017-12-14 12:17:41 +01:00
Dale Wijnand 4248f5a0af
Merge pull request #3809 from dwijnand/update-mimaPreviousArtifacts-1.1.x
update mimaPreviousArtifacts (in the 1.1.x branch)
2017-12-13 22:06:46 +00:00
Dale Wijnand 2e5aabb222
Merge pull request #3805 from eed3si9n/wip/file_uri
Encode POSIX file path to URI using u3 (file:///)
2017-12-12 17:32:42 +00:00
Eugene Yokota 06b85919ba
Encode POSIX file path to URI using u3 (file:///)
Ref https://github.com/sbt/io/pull/96

Under RFC 8089, both u1 and u3 are legal, but many of the other platforms expect traditional u3.
This will increase the compatibility/usability of sbt server, for example to integrate with Vim.
2017-12-12 16:27:14 +00:00
Dale Wijnand 7a8c89effc
Update version to 1.1.0-SNAPSHOT
.. & fix project/cross-plugins-defaults.
2017-12-12 16:27:11 +00:00
eugene yokota 609329b19e
Merge pull request #3802 from cunei/wip-templateStats-2
Revert "Alt scala parser sync workaround"
2017-12-09 00:45:26 -05:00
Antonio Cunei 5c72c3b487 Revert "Alt scala parser sync workaround"
Although in theory the fix in #3776 should be preferable to
synchronize templateStats() manually, it turns out that we
still get errors in some tests. So, reverting to a
synchronized section while we investigate.

This reverts commit ee90917cc4.
2017-12-08 19:21:14 +01:00
eugene yokota 30fd81edf6
Merge pull request #3795 from eed3si9n/wip/checksocket
Only the first session starts the server
2017-12-05 17:59:06 -05:00
Eugene Yokota 322f9b31cd Only the first session starts the server
Currently the server will try to start even if there are existing sbt sessions. This causes the second session to take over the server for Unix domain socket.

This adds a check before the server comes up and make sure that the socket is not taken.
2017-12-05 09:14:18 -05:00
Eugene Yokota 2b2c1f0568 prevent "shutdown" when server didn't come up 2017-12-05 08:04:59 -05:00
kenji yoshida 8323609053 update mimaPreviousArtifacts 2017-12-05 16:43:40 +09:00
eugene yokota 4c435a5adb
Merge pull request #3791 from eed3si9n/wip/serverLog
Fixes server log hardcoded to debug level
2017-12-04 13:33:27 -05:00
Eugene Yokota 93b3391167 Fixes server log hardcoded to debug level
Fixes #3786

To configure the log level of the server, this introduces a new task key named `serverLog`. The idea is to set this using `Global / serverLog / logLevel`. It will also check the global log level, and if all else fails, fallback to Warn.

```
    lazy val level: Level.Value = (s get serverLogLevel) orElse (s get logLevel) match {
      case Some(x) => x
      case None    => Level.Warn
    }
```
2017-12-02 15:20:54 -05:00
eugene yokota 8db6cd7a9e
Merge pull request #3785 from eed3si9n/wip/vscode-bump
Bump vscode-sbt-scala version to 0.1.0
2017-11-30 12:37:47 -05:00
Eugene Yokota 62ecd417da Bump vscode-sbt-scala version to 0.1.0 2017-11-30 12:35:40 -05:00
eugene yokota 74ddddc8e5
Merge pull request #3782 from eed3si9n/wip/bump
Merge 1.0.x + bump modules
2017-11-30 10:23:14 -05:00
Eugene Yokota 6ed3c0f534 more notes 2017-11-30 00:01:33 -05:00