Commit Graph

665 Commits

Author SHA1 Message Date
Sanjin Sehic bcfe46c019 Track all remote branches in local git repository
This change fixes bug where non-HEAD branches could not be checked out
because the local copy of a remote git repository was not tracking
them.
2012-02-13 22:02:44 -05:00
Sanjin Sehic 43142ce3b4 Fix not cleaning up when checkout of a DVCS branch fails 2012-02-13 22:02:44 -05:00
Sanjin Sehic 5232dd941e Fix resolving SVN URI with revision 2012-02-13 22:02:44 -05:00
Sanjin Sehic 837d973fd3 Remove potentially unsafe optimization in local resolver
Old implementation of the local resolver did not copy directory if it
was writable. This optimization can lead to some potential problems if
the directory is writable, but its subdirectories aren't.

New implementation of the local resolver does not have this
optimization and it always copies the directory into staging area.
2012-02-13 22:02:44 -05:00
Sanjin Sehic 5ed012c7d9 Add another run method in Resolvers for commands with no working directory 2012-02-13 22:02:44 -05:00
Sanjin Sehic 7efa24f59b Inline trivial private methods 2012-02-13 22:02:44 -05:00
Sanjin Sehic e4f809953f Implement resolver for subversion repositories
All subversion URIs have to be prefixed with 'svn:' to separate them
from URIs for other resolvers. For example, 'svn:https://server/repo'
can now be used.
2012-02-13 22:02:44 -05:00
Sanjin Sehic bc4443b408 Implement resolver for mercurial repositories
All mercurial URIs have to be prefixed with 'hg:' to separate them
from URIs for other resolvers. For example,
'hg:https://server/user/repo' can now be used.
2012-02-13 22:02:44 -05:00
Sanjin Sehic 972acc871a Allow retrieving of non-standard git URIs
Non-standard git URIs are ones that do not start with 'git:' nor end
with '.git'. An example of non-standard git URI is
'ssh://server/home/user/repo'.

The mechanism for specifying a non-standard git URI is done by
prefixing the whole URI with 'git:' to signify that it should be
handled with the git resolver. For example, non-standard git URIs like
'git:ssh://server/user/repo' and 'git:https://server/user/repo' can
now be used.
2012-02-13 22:02:44 -05:00
Sanjin Sehic 77626f5232 Optimize retrieving from git repositories
Instead of cloning from a remote git repository for each branch,
revision or tag separately, the git resolver locally clones only once
the remote git repository and then creates further local clones from
this local copy of the remote repository.

First, optimization, of course, is execution speed, because cloning
local repository is much faster than remote repository. Furthermore,
because git uses hard-linking when a clone of local repository is
created, the second optimization is in space consumption.

For example, if we have one project that uses
https://github.com/harrah/xsbt.git#v0.11.1 and second project that
uses https://github.com/harrah/xsbt.git#v0.11.2, in previous git
resolver implementation it would require two separate clones of the
remote git repository at https://github.com/harrah/xsbt.git. But, the
new git resolver requires only one clone of the remote git repository
and two local clones which take no space because of hard-linking.
2012-02-13 22:02:44 -05:00
Sanjin Sehic 942427bfa3 Extract local, remote, and git BuildLoader.Resolver from ResolveUnit 2012-02-13 22:02:44 -05:00
Mark Harrah dd51dbb999 cleanup 2012-02-13 22:02:44 -05:00
Eugene Vigdorchik 7cf1e3fe3c Remove artificial TaskKey. 2012-02-11 12:32:40 +04:00
Eugene Vigdorchik c6ea7ccd67 Remove unneeded validation. It would be really nice
if sbt allowed to show all paths in a DAG between 2 given vertices.
2012-02-10 13:26:06 +04:00
Eugene Vigdorchik 6c5d398608 Validate resolvers when making ivy configuration and publishing. 2012-02-10 13:17:25 +04:00
Mark Harrah baaf75b08a Merge pull request #361 from vigdorchik/add_ivy_force
Mirror ivy \'force\' attribute in sbt.
2012-02-08 06:43:02 -08:00
Mark Harrah bb765db6c2 drop compatibility framework definitions (dead anyway) 2012-02-07 21:56:37 -05:00
Eugene Vigdorchik be3ea741bc Mirror ivy \'force\' attribute in sbt. 2012-02-07 20:14:45 +04:00
Indrajit Raychaudhuri cc904b4d5d - Add default opt for javadoc
- Default credential file stays in `~/.sbt` now
2012-02-05 21:55:16 +05:30
Indrajit Raychaudhuri d54c520cb1 Make mapping task names more consistent, ref #317, credit @Atry 2012-02-05 21:55:15 +05:30
Mark Harrah 5fdbc86259 cleanup 2012-02-04 21:10:30 -05:00
Mark Harrah 410ba2afa9 API doc fixes 2012-02-04 21:10:30 -05:00
Eugene Vigdorchik 1fd1b7803c Add a test to check for keeping a selected url upon reload. 2012-02-04 21:10:30 -05:00
Eugene Vigdorchik 33ec1c419d Remember current URI + more tests. Review by @harrah 2012-02-02 17:15:14 +04:00
Eugene Vigdorchik 0dafd5ef26 Check for the case the project doesn't exist after reload. 2012-01-31 21:15:18 +04:00
Eugene Vigdorchik 8daa6d3279 Keep project selection upon reload. 2012-01-31 19:12:52 +04:00
Mark Harrah 482ff4978d Merge pull request #342 from vigdorchik/wip_sourcepos_eugenevigdorchik
Wip sourcepos eugenevigdorchik
2012-01-30 14:34:03 -08:00
Eugene Vigdorchik d1c799cd09 More cleanup. 2012-01-30 19:06:26 +04:00
Eugene Vigdorchik dc0a40c776 Change SourcePosition definition + minor cleanup. 2012-01-30 19:06:24 +04:00
Eugene Vigdorchik e40f735f6a Display sourcepos info when at least 1 pos known. 2012-01-30 19:06:22 +04:00
Eugene Vigdorchik 09ff0664a3 Add SourcePosition to setting. 2012-01-30 19:06:18 +04:00
Mark Harrah 98c98f9c26 split command core to main/command/ 2012-01-29 14:36:27 -05:00
Mark Harrah 26ec82ed73 Append instances for Set and Map 2012-01-27 21:09:11 -05:00
Mark Harrah f55d34f617 Add Path.allSubpaths and API documentation for mappers 2012-01-26 21:28:19 -05:00
Mark Harrah f092fb35c9 When *::main-class is set, use its value for run::main-class 2012-01-25 17:29:51 -05:00
Mark Harrah 7e71ab7c3d fix forward aggregation enabled check 2012-01-22 22:06:53 -05:00
Mark Harrah 5e155900da rework cross versioning to account for prerelease Scala versions 2012-01-22 22:06:53 -05:00
Mark Harrah 2255bd5a62 org.scala-tools.sbt -> org.scala-sbt and dropping scala-tools.org from defaults 2012-01-22 22:06:52 -05:00
Mark Harrah 3a0938878d clarify behavior of State.reload 2012-01-19 11:00:24 -05:00
Mark Harrah 58d6f34dd5 separate configuration of global plugins, staging, and settings directories. fixes #331
System propery sbt.global.plugins configures global plugins directory
  default: $sbt.global.base/plugins

System property sbt.global.staging configures global staging directory
  default: $sbt.global.base/staging

System property sbt.global.settings configures directory containing global .sbt files
  default: $sbt.global.base
2012-01-19 11:00:24 -05:00
Mark Harrah 6a7eb6c937 Merge branch 'parsing_changes' into 0.12 2012-01-15 13:09:41 -05:00
Mark Harrah d65d23bd99 make new plugin configuration style higher precedence than deprecated project/plugins/ style 2012-01-15 12:29:54 -05:00
Mark Harrah 64ffd20e15 cleanup deprecations for 0.12.0 2012-01-15 12:29:53 -05:00
Mark Harrah d146c7f84c cleanup cache-related code, aiming for unknown cause of #292 2012-01-15 12:29:53 -05:00
Mark Harrah a0300cd3b3 deprecate alternative project directory name '.sbt' 2012-01-15 12:29:53 -05:00
Mark Harrah 795b924f46 reimplement lighter support for controlling aggregation 2012-01-09 08:01:24 -05:00
Mark Harrah 82326cc899 new aggregation approach, still need exclusion mechanism 2012-01-09 08:01:24 -05:00
Mark Harrah ec48779829 moved task axis before the key 2012-01-09 08:00:29 -05:00
Mark Harrah 79bbe8f8a4 fix tab completion of new inspect variations 2012-01-09 08:00:29 -05:00
Mark Harrah fbe8630433 move calls to runExitHooks into the State.{reload,exit,reboot} commands. fixes #306 2011-12-16 08:21:54 -05:00