Commit Graph

482 Commits

Author SHA1 Message Date
Eugene Yokota 8dbed8ad88 Split proguarded launcher out to a subproject 2015-02-06 14:40:19 -05:00
Eugene Yokota f2e5d48b6b remove precompiled compiler bridges
- Scala 2.8.x or 2.9.x are no longer used that often.
- Precompiled is a cross build liability as sbt (2.10.4) depends on 2.8.x/2.9.x code.
- Scripted test was modified to check 2.8 and 2.9 compilation
2015-02-03 19:36:45 -05:00
Eugene Yokota 883792e3c3 sbt-doge 0.1.3 2015-02-03 00:40:19 -05:00
Eugene Yokota f65712e90d Fix build 2015-02-02 22:44:02 -05:00
eugene yokota be78b7fc4c Merge pull request #1759 from jedesah/topic/minor_cleanup
Minor code cleanup
2015-01-14 16:13:06 -05:00
Eugene Yokota 75e7b47718 Run scripted with sbt-maven-resolver 2015-01-12 22:01:16 -05:00
Josh Suereth e3931dbfec Create a new Ivy DependencyResolver which uses Aether.
* Here we wire Aether into the Ivy dependency chain
* Add hooks into Aether to use Ivy's http library (so credentials are configured the same)
* Create the actual Resolver which extracts metadata information from Aether
* Deprecate old Ivy-Maven integrations
* Create hooks in existing Resolver facilities to expose a flag to enable the new behavior.
* Create notes documenting the feature.
* Create a new resolver type `MavenCache` which denotes how to read/write local maven cache metadata
  correctly.  We use this type for publishM2 and mavenLocal.
* Update failing -SNAPSHOT related tests to use new Aether resolver
* Create specification for expected behavior from the new resolvers.

Known to fix #1322, #321, #647, #1616
2015-01-08 08:53:25 -05:00
Eugene Yokota 5ce7c5aaca Fixing cross building 2014-12-18 17:40:20 -05:00
Eugene Yokota a903aafd7c Fix java version check, and use scope filter 2014-12-18 13:14:04 -05:00
Eugene Yokota 4cac42f56c Factor out dependencies 2014-12-18 07:57:05 -05:00
Eugene Yokota 91de6c6b79 Multi-project build.sbt 2014-12-17 23:38:10 -05:00
Jean-Rémi Desjardins 8ef3cd5871 Revert accidental style change 2014-12-05 15:37:31 -08:00
Josh Suereth fda9252250 Merge pull request #1752 from sbt/wip/1752
Cached resolution is too verbose
2014-12-04 17:09:34 -05:00
Eugene Yokota 607b686cb2 Fixes #1752. Fixes cached resolution too verbose.
- Fixes cached resolution being too verbose
- Adds new UpdateLogging named "Default"
- When global logLevel or logLevel in update is Debug, Default will
bump up to Full UpdateLogging.
2014-12-04 12:34:30 -05:00
Jean-Rémi Desjardins ca736e55d3 Minor code cleanup 2014-12-03 09:56:34 -08:00
Josh Suereth 3c4bc23cdb First set of refactorings from review.
* Split Java analyzing compile into its own class.
* MixedAnalyzingCompiler now only does the mixing
* Start moving methods around to more-final locations
* Static analyzingCompile method now constructs a MixedAnalyzingCOmpiler and delegates to incremental compile.
2014-12-01 13:35:51 -05:00
Josh Suereth 31088791da Reset sbt version after merge. 2014-10-29 20:33:40 -04:00
Josh Suereth 9aacec8918 Bump RC version for release. 2014-10-29 20:13:25 -04:00
Josh Suereth bd2fef571e Bump version for 0.13.7-RC1 2014-10-24 16:36:05 -04:00
Eugene Yokota 3f958a5bce enable -deprecation for Scala 2.10
Enable -deprecation flag to catch old code being use when we migrate
things.
In this commit I moved error to sys.error.
2014-10-10 15:42:26 -04:00
Eugene Yokota fe8d290c17 Implemented cached resolution (minigraph caching) 2014-09-29 17:33:37 -04:00
Josh Suereth 14148c96f7 Fix #1598 - Ivy fails to load evicted information.
Upgrade to a version of ivy 2.3.0 that has a backported fix for conflict resolver.
2014-09-19 13:08:49 -04:00
Josh Suereth afd917dac3 Bump to a version of ivy that will not swap in httpclient URL handler.
When ivy finds the httpclient on the classpath, it will silently change
its url handler, and the httpclient in ivy 2.3.x has a few known
issues.
2014-09-16 09:32:19 -04:00
eugene yokota 904c8377b1 Merge pull request #1588 from sbt/wip/bump-sbt-version
Bump version for next sbt release.
2014-09-13 15:38:42 -04:00
Grzegorz Kossakowski 7885fd2558 Merge pull request #1572 from Duhemm/textanalysisformat-dependency-kinds
Don't hardcode existing relations in TextAnalysisFormat
2014-09-11 16:55:08 +02:00
Josh Suereth 8451caf93a Bump version for next sbt release. 2014-09-10 12:36:05 -04:00
Josh Suereth d9ebceebdd Scalariform refactoring. 2014-09-09 10:46:28 -04:00
Josh Suereth 5ceb247c0a Remove automated conscript generation and only generate on release.
Fixes #1558.

Note: This may mean conscript is updated less frequently, but
is better than the alternative.
2014-09-09 10:44:32 -04:00
Martin Duhem efa71548d1 Add unit tests for TextAnalysisFormat
Those tests use the random Analysis generator that is used in the
unit tests for the subproject `incremental-compiler`.

Random Analyses are serialized and then constructed back from this
representation.
2014-09-03 23:24:08 +02:00
Ben McCann 6508429d81 Fetch tyesafe artifacts using https. See http://blog.ontoillogical.com/blog/2014/07/28/how-to-take-over-any-java-developer/ 2014-08-16 16:17:07 -07:00
Eugene Yokota bc91e456f7 scalariform project/Docs.scala 2014-08-08 17:07:44 -04:00
eugene yokota 9654b2a658 Merge pull request #1497 from sbt/wip/0.13.5-merge
0.13.5 merge
2014-08-04 11:51:11 -04:00
Josh Suereth 33deeea8b3 Fix nightly push to go to snapshot repository. 2014-08-04 11:08:29 -04:00
Eugene Yokota 9d86e1c7fc Merged 0.13.5 to remove documents 2014-08-04 10:14:46 -04:00
Eugene Yokota d06bd002ff Add Release.javaVersionCheckSettings to Release.settings 2014-07-31 15:18:39 -04:00
Eugene Yokota 0a00d0625a Added sbt-javaversioncheck to the build, and bumped up sbt/ivy version to 2.3.0-sbt-14d4d23e25f354cd296c73bfff405544434d5f80 2014-07-30 19:52:59 -04:00
Eugene Yokota a1c54bfb59 Updates internal Ivy to 2.3.0-sbt-fac2aaab6f982c4424b47e6b190190bef50a6f59 for exclude rule perf 2014-07-29 22:06:05 -04:00
Eugene Yokota c8af32950d Implements eviction warning stories. #1200
This implements all stories from https://github.com/sbt/sbt/wiki/User-Stories%3A-Conflict-Warning.
When scalaVersion is no longer effective an eviction warning will display.

    Scala version was updated by one of library dependencies:
        * org.scala-lang:scala-library:2.10.2 -> 2.10.3

When there're suspected incompatibility in directly depended Java libraries,
eviction warnings will display.

   There may be incompatibilities among your library dependencies.
   Here are some of the libraries that were evicted:
      * commons-io:commons-io:1.4 -> 2.4

When there's suspected incompatiblity in directly depended Scala libraries,
eviction warnings will display.

  There may be incompatibilities among your library dependencies.
  Here are some of the libraries that were evicted:
      * com.typesafe.akka:akka-actor_2.10:2.1.4 -> 2.3.4

This also adds 'evicted' task, which displays more detailed eviction warnings.
2014-07-27 12:26:12 -04:00
Eugene Yokota efb68cf6bf whitespace change due to scalariform kicking in 2014-07-10 17:46:41 -04:00
James Roper 4d29302632 Fixed scripted newer command
The scripted newer command was effectively a noop, it always passed
because it returned false instead of throwing an exception when it
failed.

Implemented specs for most of the scripted file commands as well.
2014-06-23 15:12:34 +10:00
eugene yokota 47b5790c41 Merge pull request #1391 from sbt/wip/1390
Improve test failure message for #1390.
2014-06-06 13:24:11 -04:00
Josh Suereth fbb0e318fd Merge pull request #1396 from skyluc/2.12-support
Adds support for Scala 2.12
2014-06-05 16:26:21 -04:00
Josh Suereth 4cd5657ac1 Cleanup release settings not existing and credentials check/enforcement craziness. 2014-06-04 11:32:21 -04:00
Josh Suereth 6f28f08b78 One more fix to release script.
* Ensure completion is appropriately cross versioned
* The publish launcher task should not try to publish
  the useless root project.
2014-06-04 08:50:46 -04:00
Luc Bourlier 9c9b75c39a Adds support for Scala 2.12 2014-06-04 10:00:47 +02:00
Josh Suereth 2c3f40eb02 Improve test failure message for #1390. 2014-06-02 15:10:17 -04:00
Josh Suereth f05a16801c merge with master 2014-06-02 13:44:07 -04:00
Josh Suereth f568e710ce Also publish completions library for 2.11. 2014-06-02 13:42:27 -04:00
Josh Suereth 7f2bd2cc4b Remove nested site generation in favor of just creating Scaladoc/Sxr docs.
* Do not delete versioned docs from sbt/website project
* Just sync api/sxr directories
* Remove all build-related information for old sphinx docs.

Replaces #1385
2014-06-02 12:54:01 -04:00
Josh Suereth e0a96e3d7f Fix bug in release script due to typo.
* Fix collection typo
* Create shared command to setup 2.11 builds
* Alter snapshot detection to allow more flexible milestone versioning.
* Remove cusotm isSnapshot key for new sbt 0.13.2 isSnapshot key.
2014-05-29 22:35:44 -04:00
Josh Suereth ae02b495e6 Fix bug in release script due to typo.
* Fix collection typo
* Create shared command to setup 2.11 builds
* Alter snapshot detection to allow more flexible milestone versioning.
* Remove cusotm isSnapshot key for new sbt 0.13.2 isSnapshot key.
2014-05-28 09:37:14 -04:00
Josh Suereth 4c2d88649e Fix formatting issues and bump to sbt 0.13.5 2014-05-28 09:12:55 -04:00
Josh Suereth 89091ca4fc Merge remote-tracking branch 'origin/0.13.5' into wip/fix-doc-generation
Conflicts:
	project/Sbt.scala
2014-05-28 09:09:51 -04:00
Josh Suereth 73e8676ea5 0.13.5 release. 2014-05-27 09:35:32 -04:00
Eugene Yokota d2f07be79d Roll back Ivy to 2.3.0 for 0.13.5 2014-05-20 12:09:19 -04:00
Josh Suereth a1a784bf91 Add the ability to cross publish libraries and create a command to automatically do so. 2014-05-16 16:50:34 -04:00
Josh Suereth abffc3e1bd Bump expected 2.11 module versions so we can compile with 2.11
Add scala 2.11 test/build verification.

* Add 2.11 build configuratoin to travis ci
* Create command which runs `safe` unit tests
* Create command to test the scala 2.11 build
* Update scalacheck to 1.11.4
* Update specs2 to 2.3.11
* Fix various 2.11/deprecation removals
  and other changes.

Fix eval test failure in scala 2.11 with XML not existing.
2014-05-14 19:08:05 -04:00
eugene yokota 066a12cd2a Merge pull request #1320 from sbt/wip/bump-root-version
Bump version number for next bout of development.
2014-05-09 11:28:35 -04:00
Josh Suereth 98ed08a976 Bump version number for next bout of development. 2014-05-09 08:32:55 -04:00
Grzegorz Kossakowski 436e7078fb Enable name hashing algorithm in sbt build.
The name hashing seems to be stable enough for sbt to use it by default
now. It also greatly improves incremental compilation experience for
people working on sbt sources.
2014-05-09 14:18:46 +02:00
Josh Suereth d034561083 Scalariformed project/Sbt.scala 2014-05-07 11:52:49 -04:00
Josh Suereth 5d5d7a6c05 Add the ability to paginate scripted tests.
* Modify scripted task parser to allow "pagination" of globs
  e.g.  "*1of3" will create three pages and run page 1.
* Modify travis definition to fragment long-running test groups
  into pages so we stay under the 50 minute limit.
2014-05-07 11:06:26 -04:00
Eugene Yokota adb41611cf added scalariform 2014-05-01 12:50:07 -04:00
Eugene Yokota b730c00b75 sbt 0.13.2 2014-05-01 12:05:52 -04:00
Josh Suereth 3121f2f278 Revert "add precompiled 2.11.0"
This reverts commit 36ec103274.

This 2.11.0 dependency was causing issues with older sbt launchers
attempting to use the 2.11.0 scala release for sbt's classloader,
leading to binary incompatibility issues.
2014-04-28 07:46:44 -04:00
xuwei-k 36ec103274 add precompiled 2.11.0 2014-04-24 00:51:44 +09:00
Grzegorz Kossakowski 37e57f7940 Use dedicated api for lastCompilationTime in build definition
Since sbt 0.13.0, we have dedicated API in Analysis that gives access to
information about all compilations performed since the last time clean
was ran.

By looking at at last compilation we can determine lastCompilationTime
value.

Fixes #1272
2014-04-18 18:50:17 +02:00
eugene yokota 96558930c3 Merge pull request #1226 from sbt/wip/bump-to-latest-ivy
Bump to our own release of ivy 2.4.x
2014-04-10 10:15:26 -07:00
Josh Suereth d34ca37c40 Bump ivy version to include exclusion performance fix. 2014-03-31 16:02:39 -04:00
Eugene Yokota 02ad34442f back to 0.13.5-SNAPSHOT 2014-03-29 13:41:28 -04:00
Josh Suereth 6e72324b88 Bump to our own nightly of ivy 2.4.0 (RC1+).
* Testing the infrastructure to use our own instance of ivy
* Allow us to push bug-fixes/performance directly into ivy
  on our own pace, as we submit patches back to ivy master
2014-03-29 13:06:27 -04:00
Eugene Yokota a4a6aa0bc3 0.13.5-M2 2014-03-27 23:28:53 -04:00
Eugene Yokota f6d1044c4b 0.13.5-SNAPSHOT 2014-03-26 14:34:25 -04:00
Ismael Juma 607e061a6a Bump Scala version to 2.10.4. 2014-03-25 22:08:04 +00:00
Eugene Yokota 66ada09f06 0.13.5-M1 2014-03-25 01:49:33 -04:00
Josh Suereth 905028a6ae Bump version for further 0.13.x development. 2014-03-11 10:25:18 -04:00
Josh Suereth a8acc11fb5 Merge pull request #1130 from sbt/wip/auto-plugins
AUTO PLUGIN FEATURE!!!!
2014-02-20 16:08:01 -05:00
Grzegorz Kossakowski 4a9981720a Remove work-arounds for Scala 2.11 problematic dependencies
The ff0fd6eec6 introduced some exclusions
that were necessary for getting sbt to resolve dependencies properly
against Scala 2.11.0-M7.

Scala 2.11.0-M8 fixed its dependency structure so we can get rid of those
exclusions now.
2014-02-12 14:12:20 +01:00
Mark Harrah 162d8094ba Convert logic system test cases into unit tests.
Still TODO for auto-plugins/logic:

 * property-based tests for logic system
 * user documentation
 * (optional) 'about plugins' or similar to show more information about the auto-plugins for a project
 * (deferred) allow AutoPlugin to inject Commands directly?
 * (deferred) provide AutoPlugin functionality to arbitrary scopes instead of just at the Project level?
2014-01-24 14:37:04 -05:00
Mark Harrah b8619f4aae Main part of integrating natures into project loading. 2014-01-24 14:34:15 -05:00
Mark Harrah 322f6de655 Logic system supporting auto plugins and initial outline of AutoPlugin and Natures types.
* Not integrated into project loading
 * Doesn't yet check that negation is acyclic before execution
2014-01-24 14:30:12 -05:00
Grzegorz Kossakowski ff0fd6eec6 Update dependencies to Scala 2.11.0-M7.
I had to sprinkle some excludes due to dependency of scala-compiler M7 on
M6 modules. Those excludes won't be needed by the time M8 is out.
2014-01-18 01:09:24 +01:00
Adriaan Moors 034eb26af9 Scala 2.11 modules now under org.scala-lang.modules
Using 1.0-RC2 for scala-xml, 1.0-RC1 for scala-parser-combinators.
2014-01-18 00:04:32 +01:00
William Benton 3a1ad44c45 Support Ivy 2.3.0-final.
This entailed modifying ResolutionCache and the CustomPomParser
to reflect changes to the ResolutionCacheManager interface and
DefaultExtendsDescriptor class between Ivy 2.3.0-rc1 and
2.3.0-rc2. Specifically,

1. ResolutionCacheManager now includes two additional methods
that needed implementations in ResolutionCache:
getResolvedModuleDescriptor(mrid: ModuleRevisionId) and
saveResolvedModuleDescriptor(md: ModuleDescriptor). I adapted
the implementations for these (which are expressed primarily in
terms of other interface methods) from Ivy 2.3.0's
DefaultResolutionCacheManager.

2. Instead of taking a ModuleRevisionIdentifier and a resolved
ModuleRevisionIdentifier as its first two arguments, the
DefaultExtendsDescriptor constructor now takes a
ModuleDescriptor. This was a trivial change.

Note that ResolutionCache.getResolvedModuleDescriptor does not
appear to be used by Ivy as sbt uses Ivy and there is thus no
test coverage for its implementation. Also note that the
DefaultResolutionCacheManager object created in
Update.configureResolutionCache now requires a reference to an
IvySettings object; DRCM expects this to be non-null.
2013-12-13 14:24:37 -06:00
Mark Harrah 06deda06af Reorganized/commented proguard build configuration.
Review by @jsuereth.
2013-12-13 10:33:07 -05:00
Mark Harrah 48fb98f2d1 0.13.1 2013-12-10 10:18:42 -05:00
Grzegorz Kossakowski ec40eab92d Merge pull request #1013 from gkossakowski/used-names-extraction
Used names extraction logic
2013-12-03 03:30:21 -08:00
Grzegorz Kossakowski 304796bb7a Add support for tracking names used in Scala source files.
Tracking of used names is a component needed by the name hashing
algorithm. The extraction and storage of used names is active only when
`AnalysisCallback.nameHashing` flag is enabled and it's disabled by
default.

This change constists of two parts:

  1. Modification of Relations to include a new `names` relation
     that allows us to track used names in Scala source files
  2. Implementation of logic that extracts used names from Scala
     compilation units (that correspond to Scala source files)

The first part is straightforward: add standard set of methods in
Relations (along with their implementation) and update the logic which
serializes and deserializes Relations.

The second part is implemented as tree walk that collects all symbols
associated with trees. For each symbol we extract a simple, decoded name
and add it to a set of extracted names. Check documentation of
`ExtractUsedNames` for discussion of implementation details.

The `ExtractUsedNames` comes with unit tests grouped in
`ExtractUsedNamesSpecification`. Check that class for details.

Given the fact that we fork while running tests in `compiler-interface`
subproject and tests are ran in parallel which involves allocating
multiple Scala compiler instances we had to bump the default memory limit.

This commit contains fixes for gkossakowski/sbt#3, gkossakowski/sbt#5 and
gkossakowski/sbt#6 issues.
2013-12-03 12:27:29 +01:00
Grzegorz Kossakowski c5317a1f72 Work harder on generating unique values in generator for Analysis.
The TestCaseGenerators uses global set for ensuring that certain generated
values are unique. This is not the best design because the more properties
you check the harder is to generate new sample inputs because of already
accumulated values. This results in:

[info] + Analysis.Simple Merge and Split: OK, proved property.
[info] ! Analysis.Complex Merge and Split: Gave up after only 8 passed tests. 93 tests were discarded.

I don't have an ambition to reduce the scope of this global set but at
least I wanted to make generators to work a bit harder on generating
samples.

Instead of using `suchThat` method for filtering out non-unique samples
we use `retryUntil` that never gives up (therefore it might not
terminate). We had to upgrade to latest (1.11.1) version of scalacheck
in order to have an access to `retryUntil` method.

Also, I overridden the `identifier` to delegate to original
`Gen.identifier` but with minimal size set to be to '3'. This means,
the generated identifier will be of size 3 or larger which is needed in
order to avoid collisions.
2013-11-25 18:50:49 +01:00
Bruno Bieth e4dd71c08c execute scripted test without publishing SBT first
Saves you some time when only your test has changed.
2013-11-13 15:51:21 -05:00
Mark Harrah a92b883e23 update to ScalaCheck 1.11.0 2013-11-04 11:28:40 -05:00
Grzegorz Kossakowski a37d8d4770 Fix unstable existential type names bug.
Fix the problem with unstable names synthesized for existential
types (declared with underscore syntax) by renaming type variables
to a scheme that is guaranteed to be stable no matter where given
the existential type appears.

The sheme we use are De Bruijn-like indices that capture both position
of type variable declarion within single existential type and nesting
level of nested existential type. This way we properly support nested
existential types by avoiding name clashes.

In general, we can perform renamings like that because type variables
declared in existential types are scoped to those types so the renaming
operation is local.

There's a specs2 unit test covering instability of existential types.
The test is included in compiler-interface project and the build
definition has been modified to enable building and executing tests
in compiler-interface project. Some dependencies has been modified:

  * compiler-interface project depends on api project for testing
    (test makes us of SameAPI)
  * dependency on junit has been introduced because it's needed
    for `@RunWith` annotation which declares that specs2 unit
    test should be ran with JUnitRunner

SameAPI has been modified to expose a method that allows us to
compare two definitions.

This commit also adds `ScalaCompilerForUnitTesting` class that allows
to compile a piece of Scala code and inspect information recorded
callbacks defined in  `AnalysisCallback` interface. That class uses
existing ConsoleLogger for logging. I considered doing the same for
ConsoleReporter. There's LoggingReporter defined which would fit our
usecase but it's defined in compile subproject that compiler-interface
doesn't depend on so we roll our own.

ScalaCompilerForUnit testing uses TestCallback from compiler-interface
subproject for recording information passed to callbacks. In order
to be able to access TestCallback from compiler-interface
subproject I had to tweak dependencies between interface and
compiler-interface so test classes from the former are visible in the
latter. I also modified the TestCallback itself to accumulate apis in
a HashMap instead of a buffer of tuples for easier lookup.

An integration test has been added which tests scenario
mentioned in #823.

This commit fixes #823.
2013-10-29 16:39:50 +01:00
Mark Harrah d6ca66d406 Docs: sitemap generator, basic robots.txt. Fixes #916. 2013-10-17 15:00:48 -04:00
Mark Harrah 9a85396d4f Include link to source on GitHub at bottom of the page. Fixes #921. 2013-10-16 19:26:25 -04:00
Mark Harrah d4aa7bf0e9 drop unused mutable data type generator 2013-10-08 13:38:33 -04:00
Mark Harrah fb81ca67d8 bump Scala version to 2.10.3 2013-10-02 19:39:17 -04:00
Mark Harrah 72125e73ce Build: scope root sources to 'doc' task since they shouldn't be compiled normally. 2013-09-26 09:17:07 -04:00
Mark Harrah b2599c1bb1 Restore sxr support and fix links to sxr'd sources. Fixes #863. 2013-09-24 11:34:14 -04:00
Mark Harrah 5ecc16df24 Docs: use different local directory for ghpages repository for snapshots and stable updates. 2013-09-22 13:46:34 -04:00
Mark Harrah 7b1b33758c Convert -classpath to CLASSPATH when forking on Windows and length exceeds a heuristic maximum. Fixes #755. 2013-09-11 18:22:16 -04:00