Commit Graph

17940 Commits

Author SHA1 Message Date
Eugene Yokota ddd5abc37b Bump node modules for security fixes 2019-02-22 10:51:54 -05:00
eugene yokota b747309fb5
Merge pull request #4549 from retronym/topic/currun
Avoid NPE on Run.<init>
2019-02-21 21:11:50 -05:00
Jason Zaugg 3cbbe93c6e Avoid NPE on Run.<init> 2019-02-22 10:26:10 +10:00
Scala steward b747d2598b Update slf4j-api to 1.7.26 (#36) 2019-02-19 13:02:19 +01:00
Alexandre Archambault bb3e0f398a
Merge pull request #35 from alexarchambault/develop
Less flaky handling of special project org.scala-sbt:global-plugins…
2019-02-18 14:52:11 +01:00
Alexandre Archambault 399e84efd5 Warn in case of source dependencies where sbt-coursier isn't enabled 2019-02-18 14:03:54 +01:00
Alexandre Archambault 8e4fb146d8 Unused import 2019-02-18 14:03:54 +01:00
Alexandre Archambault 5377b537b1 Allow to disable publishing Javadoc with -Dpublish.javadoc
Useful when testing the plugin locally
2019-02-18 14:03:54 +01:00
Alexandre Archambault 3eb210eb1b Less flaky handling of special project org.scala-sbt:global-plugins 2019-02-18 14:03:54 +01:00
Ethan Atkins 45f5019ee0
Merge pull request #4544 from eatkins/gc-on-idle
Run gc when idle
2019-02-15 10:58:41 -08:00
Ethan Atkins fcd24ba7cd Reduce command polling period
The only thing this function does is poll a queue and check a deadline.
There is no need to put such a large sleep duration in.
2019-02-14 21:13:07 -08:00
Ethan Atkins c37f2607f1 Lint CommandExchange.scala
Clears out intellij warnings.
2019-02-14 21:09:44 -08:00
Ethan Atkins faf6348a16 Run gc when idle
I often find that when I run a command it takes a long time to start up
because sbt triggers a full gc. To improve the ux, I update the command
exchange to run full gc only once while it's waiting for a command to
run and only after the user has been idle for at least one minute.

Bonus: optimize imports
2019-02-14 21:09:17 -08:00
eugene yokota 55c46c6ba8
Merge pull request #4542 from smarter/less-dotty
Remove Dotty handling in scalaInstance
2019-02-13 19:12:08 -05:00
Alexandre Archambault 145d9eeb44
Merge pull request #34 from alexarchambault/topic/coursier-1.1.0-M11
Switch to coursier 1.1.0-M11-1
2019-02-13 12:16:36 +01:00
Alexandre Archambault 7c5b8479ea Adjust dependency graph printing 2019-02-13 10:04:54 +01:00
Guillaume Martres 85f91e76ca Remove Dotty handling in scalaInstance
sbt-dotty 0.3.0 (https://github.com/lampepfl/dotty/pull/5835) sets
`managedScalaInstance := false` and does everything by itself, so this
isn't needed anymore.
2019-02-12 23:30:45 +01:00
Alexandre Archambault bb45ca7f5d Renaming 2019-02-06 15:22:58 -08:00
Alexandre Archambault 1390d319b1 Instantiate logger earlier, only keep one instance around
The loggers are now supposed to be re-usable (which simplifies their
handling)
2019-02-06 15:22:52 -08:00
Alexandre Archambault bc69e0b11a Start to use bits of the high level API of coursier
Its parameters mostly
2019-02-06 15:22:42 -08:00
Alexandre Archambault 4226df911d Switch to coursier 1.1.0-M11-1 2019-02-06 15:20:51 -08:00
Dale Wijnand 8df2807cd1
Merge pull request #4533 from eatkins/kind-projector
Add meaningful toString to values in TypeFunctions
2019-02-06 21:44:36 +01:00
eugene yokota 62471c6215
Merge pull request #191 from eatkins/avoid-io
Add file FileInfo factory applys without io
2019-02-06 14:52:39 -05:00
Stefan Wachter 9780c6218f unset immediatly exit flag (set +e) in launch script 2019-02-06 17:48:39 +01:00
Ethan Atkins 5b198b20be Add file FileInfo factory applys without io
It may be the case that the file property is already known and we can
avoid performing additional io by just passing in the value directly.
2019-02-05 10:00:27 -08:00
eugene yokota b28d203910
Merge pull request #254 from er1c/fix-253
Simplify the debug in execRunner and fix the $java_args[@] expansion fixes #253
2019-02-05 00:02:00 -05:00
Eric Peters 2d21c0fd2a Simplify the debug in execRunner and fix the $java_args[@] expansion, fixes #253 2019-02-04 20:38:10 -08:00
eugene yokota fbadfabfe2
Merge pull request #4538 from eatkins/compiler-cache
Clear compiler cache in clearCaches
2019-02-04 10:27:14 -05:00
eugene yokota e73d1fb7c6
Merge pull request #4537 from eatkins/allow-watch-loops
Allow watch loops
2019-02-04 10:25:11 -05:00
eugene yokota 7b61fcb44f
Merge pull request #4535 from eatkins/stamped-file
Stamped file
2019-02-04 10:18:11 -05:00
Ethan Atkins e8af828c73 Add FileCacheEntry
Previously, we were leaking the internal details of incremental
compilation to users by defining FileTree(DataView|Repository)[Stamp].
To avoid this, I introduce the new class FileCacheEntry that is quite
similar to Stamp except defined using scala Options rather than java
Optionals. The implementation class just delegates to an actual Stamp
and I provided a private[sbt] ops class that adds a
method `stamp` to FileCacheEntry. This will usually just extract the
stamp from the implementation class. This allows us to use
FileCacheEntry almost interchangeably with Stamp while still avoiding
exposing users to Stamp.
2019-02-02 16:03:59 -08:00
Ethan Atkins ba0494df14 Stop Stamped from inheriting File and TypedPath
In the FileTreeDataView use case, we were previously working with
FileTreeDataView[Stamped], which actually contained a lot of redundant
information because FileTreeDataView.Entry[_] has a toTypedPath method
that could be used to read the path related fields in Stamped. Instead,
we can just return the Stamp itself in FileTreeDataView.list* methods
and convert to Stamped.File where needed (i.e. in ExternalHooks).

Also move BasicKeys.globalFileTreeView to Keys since it isn't actually
used in the main-command project.
2019-02-02 12:22:57 -08:00
Ethan Atkins 0bdc30b60b Rename StampedFile to Stamped 2019-02-02 12:22:57 -08:00
Ethan Atkins d39bb96c41 Move StampedFile into its own file 2019-02-02 12:22:57 -08:00
Ethan Atkins 602554a411 Add scaladoc for StampedFile 2019-02-02 12:22:57 -08:00
Ethan Atkins f44e2a2e74 Clear compiler cache in clearCaches
Resident compilation actually works pretty well most of the time*,
but if there ever is an issue with the cached compilation, we should be
able to easily clear the cache.

* I've only had issues when package objects are involved
2019-02-02 12:20:32 -08:00
Ethan Atkins 116d2ae815 Use ? instead of extracting state
I was unaware of the '?' method when I wrote this.
2019-02-01 18:01:56 -08:00
Ethan Atkins 2ef97768a0 Don't attempt to prevent certain watch loops
If the managedSources task writes into an unmanaged source directory,
that would cause an infinite loop. I don't think it's worth doing out of
band task execution to try and prevent this.
2019-02-01 18:01:56 -08:00
Ethan Atkins f14bc7a503
Merge pull request #4527 from eatkins/scripted-classloader
Use custom classloader for scripted tests
2019-02-01 13:21:28 -08:00
Ethan Atkins 51f295a922
Merge branch 'develop' into scripted-classloader 2019-02-01 12:30:25 -08:00
Alexandre Archambault f4cc16ee3f
Merge pull request #31 from coursier/topic/coursier-1.1.0-M10
Switch to coursier 1.1.0-M10
2019-02-01 09:45:20 +01:00
Ethan Atkins efa52143d0 Make types private
While the AnyLeft and AnyRight types are necessary to make the extension
class work, I don't want to leak the AnyLeft or AnyRight traits into the
public api. It wasn't neceessary to annotate `some`, but it's good
practice to annotate anything public anyway.
2019-01-31 21:47:33 -08:00
Ethan Atkins 9b40a0e585 Add meaningful toString to TypeFunctions
It can be hard to debug these because the toString output for a kind
projector plugin provided lambda is inscrutable.
2019-01-31 21:47:33 -08:00
Ethan Atkins 16e7c70035 Lint TypeFunctions.scala 2019-01-31 21:47:33 -08:00
eugene yokota 1c5608e1dd
Merge pull request #4534 from eatkins/misc-fixups
Misc fixups
2019-01-31 21:19:21 -05:00
Ethan Atkins 7b8ed4d13f Allow sbt scripted tests to run in parallel
I'm not sure if this is a huge benefit or not, but it's nice to have the
option to run the scripted tests in parallel. The default behavior
should be the same as before.
2019-01-31 17:43:14 -08:00
Ethan Atkins 9023b58f83 Remove debug commands in scripted
These just create noise.
2019-01-31 17:43:14 -08:00
Ethan Atkins b2c9d3e2cf Use custom classloader for scripted tests
We had previously used reflection to load the bridge class, but
continued using sbt's default classloader. This was problematic because
the metabuild could have a different classpath from that required by the
scripted tests.

Bonus: scalafmt

Fixes: #4514
2019-01-31 17:43:14 -08:00
eugene yokota dc870e19b1
Merge pull request #4529 from eatkins/community-build-runner
Fix community build
2019-01-31 20:25:49 -05:00
eugene yokota 986abb3882
Merge pull request #4532 from eatkins/system-lint
System lint
2019-01-31 20:23:44 -05:00