Commit Graph

112 Commits

Author SHA1 Message Date
Grzegorz Kossakowski 6c5e4ae21c Follow source layout convention supported by Eclipse.
Moved source files so directory structure follow package
structure. That makes it possible to use Scala Eclipse plugin
with sbt's source code.
2012-12-07 10:27:08 -08:00
Mark Harrah 237b80eb22 Transition to all camelCase key labels.
1. Hyphenated labels are still accepted when parsing scoped keys (so 'sbt test-only' still works)
   There is currently no timeline for removing this support for hyphenated keys.
2. Only camelCase is shown for tab completion.
3. AttributeKey.rawLabel provides the unnormalized label.
   This should only be used to implement support for accepting hyphenated keys as input for compatibility.
4. AttributeKey.normLabel provides the normalized label (hyphenated converted to camelCase)
2012-11-17 20:23:07 -05:00
Mark Harrah ed41547a47 InputTask macro
Similar to task macros, the parsed value is accessed by calling `parsed`
on a Parser[T], Initialize[Parser[T]], or Initialize[State => Parser[T]].
Values of tasks and settings may be accessed as usual via `value`.
2012-11-17 20:23:07 -05:00
Mark Harrah 64e000a37d Properly apply transformations to dynamic tasks.
That is, implement Initialize[Task[T]].flatten correctly.
This requires preserving the transformations applied in a scope so that
they can be applied to an Initialize value after static settings have been
evaluated.
2012-11-17 20:23:06 -05:00
Mark Harrah c95df4681b task setting macros for :=, +=, ++=
also, bump to 2.10.0-M6
2012-11-17 20:19:24 -05:00
Mark Harrah 15fec197c3 2.10.0-M5, different arity generalization
1. KList[M[_]] now instead of KList[HL <: HList, M[_]]
  a. head, tail work properly in this variant
  b. disadvantage is that full type not easily transformed to new type constructor
2. AList abstracts on K[L[x]], a higher order type constructor.
 A. Instances written for:
  a. KList
  b. Seq[M[T]] for a fixed T
  c. TupleN
  d. single values
  e. operate on one type constructor when nested
 B. Main disadvantage is type inference.  It just doesn't happen for K[L[x]].
    This is mitigated by AList being used internally and rarely needing to construct a K.
2012-11-17 20:19:24 -05:00
Mark Harrah dbe4b74c10 reorganization of main/
* split several source files
* move base settings sources (Scope, Structure, ...) into main/settings/
* breaks cycles.  In particular, setting system moved from Project to Def
2012-11-17 20:19:24 -05:00
Mark Harrah 19315265c1 taking care of deprecations removed in Scala master 2012-11-14 11:48:06 -05:00
Mark Harrah c8ffd6a54d better error message for null setting values 2012-09-18 13:22:40 -04:00
Eugene Vigdorchik b65a7078f1 Fix compilation error for 2.10.0-M5 for all but main project. 2012-07-17 15:20:37 -04:00
Mark Harrah 9fea4d1703 methods for working with Scala identifiers 2012-07-13 14:33:27 -04:00
Eugene Vigdorchik 35cfba21c0 Break compiler dependency from 'collection' project. 2012-07-13 14:33:26 -04:00
Mark Harrah fbb09b1433 fix task tests 2012-07-01 15:16:41 -04:00
Mark Harrah 94b4a3784a rank settings, tasks and use this to restrict help/settings/tasks output. fixes #315 2012-03-25 20:35:09 -04:00
Mark Harrah c7c4969eb7 Revert "work around for 2.10. pattern matching on KNil now requires KNil()"
This reverts commit 2f726b34c3.

This commit caused "java.lang.Error: typeConstructor inapplicable for <none>" when running 'sxr'
2012-03-17 22:58:13 -04:00
Mark Harrah 8fc5db4a8a work around for 2.10. pattern matching on KNil now requires KNil() 2012-03-17 19:31:03 -04:00
Indrajit Raychaudhuri 51db55d847 Replace `Pair.apply` with `Util.pairID`, avoids extra class generation 2012-03-12 05:25:12 +05:30
Mark Harrah d6bc087271 handle absence of CONT signal 2012-03-09 13:38:45 -05:00
Mark Harrah 1848d14815 handle CONT signal to reset JLine after resuming from stop. fixes #394 2012-03-09 07:08:38 -05:00
Mark Harrah 5893aa0e55 cleanup SourcePosition hierarchy 2012-02-25 12:01:07 -05:00
Eugene Vigdorchik 786fe5f4ce Remember the range for settings read from .sbt files 2012-02-16 16:58:51 +04:00
Mark Harrah 6e90399a30 Merge pull request #342 from vigdorchik/wip_sourcepos_eugenevigdorchik
Wip sourcepos eugenevigdorchik
2012-01-30 14:34:03 -08:00
Eugene Vigdorchik e2c1ef32fa More cleanup. 2012-01-30 19:06:26 +04:00
Eugene Vigdorchik 5f0774fe9a Change SourcePosition definition + minor cleanup. 2012-01-30 19:06:24 +04:00
Eugene Vigdorchik c6cba20682 Add SourcePosition to setting. 2012-01-30 19:06:18 +04:00
Mark Harrah 4945534614 split command core to main/command/ 2012-01-29 14:36:27 -05:00
Mark Harrah 74eaee5a5e new aggregation approach, still need exclusion mechanism 2012-01-09 08:01:24 -05:00
Mark Harrah 392ec5150a moved task axis before the key 2012-01-09 08:00:29 -05:00
Mark Harrah 9e708b17e2 fixes #280. sort aggregate and classpath dependencies separately to keep cycle detection for them separate 2011-11-27 17:48:01 -05:00
Mark Harrah b94c6e8949 in cyclic error message, put each node string on different line 2011-11-05 08:53:42 -04:00
Mark Harrah 64bf50cd08 task execution interruptible using ctrl+c. fixes #228,#229
- interrupts task execution only
- no further tasks scheduled
- existing tasks interrupted
- a task must terminate any other started threads when interrupted
- set cancelable to true to enable
- currently, 'run' properly terminates if the application properly
   terminates when interrupted
- 'console' does not, 'test' depends on the test framework

- also bundled: set connectInput to true to connect standard input to forked run
2011-10-18 22:43:25 -04:00
Mark Harrah 5898cba4a8 brief API documentation on some core settings types 2011-10-16 20:20:45 -04:00
Mark Harrah f18c44d00d fix stackoverflow caused by using List.separate, as tracked down by pvlugter 2011-10-09 21:48:15 -04:00
Mark Harrah ba4c6de918 generalize addArtifact arguments to Initialize[...]. fixes #207 2011-10-01 14:40:14 -04:00
Mark Harrah 5874d45525 local settings, sbt-package-private for now 2011-10-01 14:40:14 -04:00
Mark Harrah 7d85f3c047 fix order of returned lists in Util.separate 2011-09-26 08:20:07 -04:00
Mark Harrah fdb47eca8d fix dependsOn breakage from Initialize rework 2011-08-26 23:27:03 -04:00
Mark Harrah 8e4906f410 fix undefined key suggestion for updating settings 2011-08-14 10:53:38 -04:00
Mark Harrah 8ce9950327 allow setting initialization to be partially dynamic and run in parallel 2011-08-14 10:53:37 -04:00
Mark Harrah 0b5e6484ba drop unused KApply from settings 2011-08-14 10:53:37 -04:00
Mark Harrah 93b64e0fd3 clean up undefined reference checking to be a proper function 2011-08-14 10:53:37 -04:00
Mark Harrah 01b27f5875 Settings overhaul, intended to be source compatible where it matters.
Moves many methods previously provided by implicit conversions directly onto the classes
  for better discoverability, especially with scaladoc.

1. Initialize now allowed in more places.  Minor renamings in Initialize to avoid conflicts
  a. map -> apply
  b. get -> evaluate
2. Identity on Scoped* is deprecated- it is now redundant
3. Can now use += and <+= for String, Int, Long, Double settings.
  There may be some problematic corner cases in inference, especially with +=, ++, <+=, <++=
4. Some classes with a scoped: ScopedKey[T] method now have scopedKey: ScopedKey[T] instead.
5. The implicit conversion to ScopedKey[T] is now deprecated.  Use the scopedKey method.
6. :== and ::= are now private[sbt] to better reflect that they were internal use only.
2011-08-14 10:53:37 -04:00
Mark Harrah ebddc4009f fix ScalaProviderTest 2011-08-14 10:53:37 -04:00
Mark Harrah baea865ecf try out simplified display of scoped keys 2011-08-04 07:20:25 -04:00
Mark Harrah 96d46b2c7a Seq[Setting[_]] <=> SettingsDefinition 2011-07-30 18:11:20 -04:00
Mark Harrah 65c1320c60 for undefined references, suggest the nearest defined scope that is more specific if it exists. fixes #135 2011-07-27 22:35:20 -04:00
Mark Harrah 9c70e479d8 display all undefined settings at once 2011-07-25 21:59:22 -04:00
Mark Harrah a6dd6b07b5 proper resolvedScoped implementation 2011-07-19 21:29:05 -04:00
Mark Harrah a6f7e9840c global settings preparation: separate compilation/loading stages of Eval 2011-07-09 16:54:41 -04:00
Mark Harrah a612cc0ba1 settings example and simple test 2011-06-29 21:44:55 -04:00