Commit Graph

10049 Commits

Author SHA1 Message Date
eugene yokota 0ecf120008
Merge pull request #5987 from eed3si9n/wip/bump
Zinc 1.4.1
2020-10-19 09:56:43 -04:00
Eugene Yokota 8007d08158 Zinc 1.4.1 2020-10-19 01:47:11 -04:00
eugene yokota 2f7cc6e9e9
Merge pull request #5985 from xirc/use-lint-xxx-filter-in-test
Use lint***Filter instead of ***LintKeys for more reliable tests
2020-10-18 14:01:17 -04:00
Taichi Yamakawa 1193f44be2 Use lint***Filter instead of ***LintKeys for more reliable test
Below functions pass lintIncludeFilter and lintExcludeFilter to lintUnusedinstead of includeLintKeys and excludeLintKeys respectively.
- sbt.internal.LintUnused#lintUnusedTask
- sbt.internal.LintUnused#lintUnusedFunc
Therefore, in the test, we had better to use lint***Filter instead of ***LintKeys.
2020-10-18 18:20:23 +09:00
eugene yokota 28833db333
Merge pull request #5983 from xirc/issues/5955
Add `shellPrompt` into excludeLintKeys
2020-10-18 04:06:28 -04:00
eugene yokota a9f62f8453
Merge pull request #5984 from xuwei-k/dotty-sandwich-scala-js
Scala-2-dependsOn-Scala-3 feature with Scala.js
2020-10-18 04:05:43 -04:00
xuwei-k bbdd11150b remove unused code 2020-10-18 15:11:41 +09:00
xuwei-k d582dfc4be Scala-2-dependsOn-Scala-3 feature with Scala.js
fix 5971
2020-10-18 15:11:41 +09:00
Taichi Yamakawa b5bd3b0211
Merge branch 'develop' into issues/5955 2020-10-18 15:00:48 +09:00
Taichi Yamakawa cb7a08dfe2 Add `shellPrompt` into excludeLintKeys
Resolve the issue https://github.com/sbt/sbt/issues/5955
2020-10-18 14:54:54 +09:00
kenji yoshida 84b84ec58d
Update dotty versions in scripted tests (#5982) 2020-10-18 14:06:44 +09:00
eugene yokota 3266d77862
Merge pull request #5979 from eed3si9n/wip/junit
bump JUnit
2020-10-17 05:00:02 -04:00
Eugene Yokota 7ba59dba9a bump JUnit
There's a security advisory on JUnit 4.
2020-10-17 04:11:33 -04:00
eugene yokota 2dc799b2bd
Merge pull request #5975 from eatkins/ctrl+d
Don't throw ClosedException on ctrl+d
2020-10-15 14:36:59 -04:00
Ethan Atkins 72991be702 Don't throw ClosedException on ctrl+d
Issue #5974 reported that ctrl+d was not working as expected in the
scala 2.13.{2,3} console. This was because we were throwing an exception
whenever ctrl+d was read instead of allowing the jline line reader to
handle it. I can't remember exactly why I added the throw here but I
validated that both the sbt shell and the scala console had the expected
behavior from the comments in #5974 after this change.
2020-10-14 20:25:31 -07:00
eugene yokota b4b688583e
Merge pull request #5973 from xuwei-k/jline-3-inputrc
load .inputrc file
2020-10-14 08:32:18 -04:00
xuwei-k 244784c78e load .inputrc file
I think jline2 automatically load ".inputrc" file. But jline3 changed behavior.
2020-10-14 17:13:53 +09:00
Ethan Atkins 8e4ec1697b
Merge pull request #5972 from eatkins/symlink-target
Check if target is directory before creating
2020-10-13 20:02:51 -07:00
Ethan Atkins efec7bce31 Check if target is directory before creating
When project/target is a symbolic link, sbt 1.4.0 crashes on startup
because Files.createDirectories will throw a FileAlreadyExistsException.
The fix is to first check if the target directory exists before trying
to create it.
2020-10-13 08:17:22 -07:00
eugene yokota ca8c1e704d
Merge pull request #5939 from eatkins/running-init
Initialize value before starting thread
2020-10-11 15:39:54 -04:00
Ethan Atkins f3f40d6442 Initialize value before starting thread
Depending on how quickly the thread starts up, this can cause an NPE
(see #5938).
2020-10-11 11:39:16 -07:00
eugene yokota d0b8cf0984
Merge pull request #5932 from aaabramov/feature/3212/new-plugins-view
Brings new `plugins` command output message as per #3212
2020-10-11 13:19:16 -04:00
eugene yokota f02edee1d5
Merge pull request #5956 from adpi2/improve-bsp-reporter
Fix #5950: Better BSP reporting
2020-10-11 13:16:30 -04:00
eugene yokota 21c73c5bd7
Merge pull request #5967 from naderghanbari/fix-5959-dep-html
Fix #5959: dependencyBrowseGraph fails with Couldn't load 'graph.html'
2020-10-11 13:15:08 -04:00
eugene yokota b806d3ed3d
Merge pull request #5964 from rdesgroppes/detect-adoptopenjdk-on-macos
Detect AdoptOpenJDK on macOS
2020-10-11 13:12:15 -04:00
eugene yokota 916498c0c2
Merge pull request #5948 from adpi2/fix-custom-reporter
Fix #5935: Introduce bspReporter key
2020-10-11 13:10:34 -04:00
Nader Ghanbari 75be157679 Use cdnjs and github instead of samsarin.com 2020-10-11 12:03:32 -04:00
Adrien Piquerez efb8bc4ec0 Use Zinc analysis in BuildServerReporter 2020-10-11 09:09:13 +02:00
Adrien Piquerez 93ad022dca Introduce bspReporter key 2020-10-11 09:08:12 +02:00
Nader Ghanbari 495118a297
Fix #5959 add missing html resources
- Add missing graph.html and tree.html resources from
https://github.com/sbt/sbt-dependency-graph
2020-10-10 23:00:20 -04:00
eugene yokota b1e4d5e3aa
Merge pull request #5954 from eatkins/new-input
Don't enter raw mode preemptively
2020-10-10 20:17:47 -04:00
eugene yokota aec55af083
Merge pull request #5966 from eatkins/piped-output-fix
Remove ansi control characters from piped output
2020-10-10 20:13:39 -04:00
eugene yokota bfb7d4019b
Merge pull request #5960 from eatkins/ci-color
Set SimpleTerminal properties based on system props
2020-10-10 20:00:53 -04:00
eugene yokota 1059674ef8
Merge pull request #5961 from xuwei-k/pullRemoteCache-semanticdb
preserve semanticdb files in pullRemoteCache task
2020-10-10 19:49:05 -04:00
Ethan Atkins 40752ff67a Remove ansi control characters from piped output
When piping an sbt task to a file, the expectation is that sbt will not
write ansi control characters and colors unless the users specifies that
with, e.g. -D.sbt.color=true. With sbt 1.4.0, all output bytes are
routed through the progress output processor which tries to ensure that
progress lines are not interleaved with log lines. The issue was that
the hasProgress flag was being set to true for the server process even
when the formatEnabledInEnv flag was set to false. This caused each log
line to have a leading clear screen before cursor ansi control code
written which would appear in the output file.
2020-10-09 10:16:59 -07:00
Regis Desgroppes 63b375aa0f Detect AdoptOpenJDK on macOS 2020-10-09 17:07:42 +02:00
xuwei-k e0e11c71d5 preserve semanticdb files in pullRemoteCache task 2020-10-09 17:54:35 +09:00
Ethan Atkins f9bc9049ee Set SimpleTerminal properties based on system props
When running sbt 1.4.0 with -Dsbt.ci=true and -Dsbt.color=true, there is
no color output. This was because in this scenario, a SimpleTerminal was
used and isAnsiSupported and isColorEnabled were hardcoded to false
rather than reading the values from the system properties.
2020-10-08 09:36:19 -07:00
Ethan Atkins b057e58792 Don't enter raw mode preemptively
The user input is not echoed in sbt new because we were switching to raw
mode when creating the console terminal. I can't quite remember why I
was entering raw mode preemptively but it doesn't seem like the best
idea.
2020-10-07 09:40:51 -07:00
eugene yokota a2fc24bb6f
Merge pull request #5947 from eatkins/windows-cancellation
Fix ctrl+c handling on windows
2020-10-06 23:14:18 -04:00
Ethan Atkins 1892f04211 Fix ctrl+c handling on windows
In windows, it is necessary for the console mode to include the
ENABLE_PROCESS_INPUT flag in order for ctrl+c to be treated as a signal
rather than a character. In jline 2, the ENABLE_PROCESS_INPUT flag was
preserved whenever the console mode was changed but in jline 3, it was
not. It is easy enough to manually set the flag after entering and
exiting raw mode and setting attributes (which are the apis that change
the console mode on windows).
2020-10-06 13:29:08 -07:00
eugene yokota 6865526d3d
Merge pull request #5944 from eatkins/sbt-snapshot-version
Bump sbt snapshot version
2020-10-06 16:21:10 -04:00
eugene yokota 715bccacd9
Merge pull request #5945 from eatkins/boot-system-in-fix
Fix sbt hangs with invalid build.sbt and --batch
2020-10-06 16:20:54 -04:00
Andrii aae6493701
Merge branch 'develop' into feature/3212/new-plugins-view 2020-10-06 23:08:41 +03:00
Andrii Abramov 6061072937 Brings new `plugins` command output message as per #3212 2020-10-06 23:06:38 +03:00
eugene yokota 42e8c9366d
Merge pull request #5946 from eatkins/no-prompt
Fix line reader for jEdit
2020-10-06 15:44:34 -04:00
Ethan Atkins 10c549a0b9 Fix sbt hangs with invalid build.sbt and --batch
When sbt is starting up and there is an error with the build loading, we
need to read input from the user to determine to restart the build or
not. What is tricky is that there are potentially two sources of input:
thin clients connected through the boot server socket and the actual sbt
console process. If there are not connected thin clients and no system
console is available, we should return -1 in System.in.read, which will
cause sbt to exit.
2020-10-06 11:43:00 -07:00
Ethan Atkins 63f2684219 Bump sbt snapshot version 2020-10-06 11:34:12 -07:00
Ethan Atkins 76128a9380 Read input from dumb terminals
On my computer with jEdit, input is not read because the console input
stream was overridden to be a blocking input stream that never returned
input. While debugging the server test hangs, I added some logic to
prevent us from trying to read from System.in when System.console ==
null but I now realize that was a mistake because of situations like
ides or editors launching an sbt shell.
2020-10-06 09:55:49 -07:00
Ethan Atkins 08aa64e703 Restore terminal prompt for some dumb terminals
A user reported that no prompt was displayed when they used sbt from the
jEdit console. The reason no prompt was displayed was because
System.console was null which caused the ConsoleChannel to be
initialized with its prompt set to NoPrompt. I don't remember why it was
doing this but this bug seems worse than whatever it was trying to
address.
2020-10-06 09:55:49 -07:00