@@ -27,27 +27,42 @@ Add the following to your `project/plugins.sbt` or `~/.sbt/0.13/plugins/plugins.
2727
2828additionally, use one of the older README.md files: (https://github.com/sbt/sbt-git/blob/v0.7.1/README.md )
2929
30- ### Using JGit ###
30+ ### JGit ###
3131
32- If you do not have git installed and available on your path (e.g. you use windows),
33- make sure your ` git.sbt ` or ` ~/.sbt/0.13/git.sbt ` file looks like this:
32+ JGit is a Java interface to git that allows some git operations to be
33+ performed in the JVM without invoking an external git executable. By default,
34+ this plugin uses JGit for read-only operations such as inspecting HEAD; for
35+ write operations, it assumes a git executable is present and on the PATH and
36+ it uses that.
37+
38+ In certain circumstances you may want to force the use of JGit or an
39+ executable for both read-only and read-write operations; for example, if no
40+ git executable is present (e.g. you use windows and you haven't installed git
41+ or it's not on your PATH) you need to disable the console interface, or if
42+ you rely on a git feature that JGit does not support (e.g. worktrees) you need
43+ to disable the JGit interface.
44+
45+ The following settings will force the use of only JGit or a git executable,
46+ respectively:
47+
48+ * ` useJGit `
49+ * ` useReadableConsoleGit `
50+
51+ These settings can be included in your project's ` git.sbt ` or in
52+ ` ~/.sbt/1.0/git.sbt ` -- for example, if no git executable is installed,
53+ either file can have the following contents:
3454
3555 useJGit
3656
37- Or you can type this into the prompt:
57+ Or you can ` set ` the appropriate setting in the sbt prompt:
3858
39- > set useJGit
59+ > set useReadableConsoleGit
4060 [info] Reapplying settings...
4161 [info] Set current project to scala-arm (in build file:...)
4262 > session save
4363 [info] Reapplying settings...
4464 [info] Set current project to scala-arm (in build file:...)
4565
46- This will enable a java-only GIT solution that, while not supporting all the same
47- commands that can be run in the standard git command line, is good enough for most
48- git activities.
49-
50-
5166## Versioning with Git ##
5267
5368You can begin to use git to control your project versions.
0 commit comments