Debian Codegraph @

maven-scm-providers/maven-scm-providers-git/maven-scm-provider-jgit/src/site/markdown/index.md.vm

raw
1 <!---
2 Licensed to the Apache Software Foundation (ASF) under one
3 or more contributor license agreements. See the NOTICE file
4 distributed with this work for additional information
5 regarding copyright ownership. The ASF licenses this file
6 to you under the Apache License, Version 2.0 (the
7 "License"); you may not use this file except in compliance
8 with the License. You may obtain a copy of the License at
9
10 http://www.apache.org/licenses/LICENSE-2.0
11
12 Unless required by applicable law or agreed to in writing,
13 software distributed under the License is distributed on an
14 "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15 KIND, either express or implied. See the License for the
16 specific language governing permissions and limitations
17 under the License.
18 -->
19
20 maven-scm-provider-jgit
21 ===
22
23 This scm provider implementation allows the usage of git with the release and scm plugin without having to install a native git client.
24 This implementation can use both username and password, or public/private keys to authenticate the requests to a remote
25 repository like GitHub. At the moment, public/private keys are only supported for SSH access.
26
27 Configuration
28 ---
29
30 Usage with the `maven-release-plugin`
31
32 <plugin>
33 <groupId>org.apache.maven.plugins</groupId>
34 <artifactId>maven-release-plugin</artifactId>
35 <version>2.3</version>
36 <configuration>
37 <providerImplementations>
38 <git>jgit</git>
39 </providerImplementations>
40 </configuration>
41 <dependencies>
42 <dependency>
43 <groupId>org.apache.maven.scm</groupId>
44 <artifactId>maven-scm-provider-jgit</artifactId>
45 <version>${project.version}</version>
46 </dependency>
47 </dependencies>
48 </plugin>
49
50 Usage with the `maven-scm-plugin`
51
52 <plugin>
53 <groupId>org.apache.maven.plugins</groupId>
54 <artifactId>maven-scm-plugin</artifactId>
55 <version>${project.version}</version>
56 <configuration>
57 <providerImplementations>
58 <git>jgit</git>
59 </providerImplementations>
60 </configuration>
61 <dependencies>
62 <dependency>
63 <groupId>org.apache.maven.scm</groupId>
64 <artifactId>maven-scm-provider-jgit</artifactId>
65 <version>${project.version}</version>
66 </dependency>
67 </dependencies>
68 </plugin>
69
70 Public/private key configuration in settings.xml - for use with ssh URLs like ssh://[email protected]/apache/maven-scm
71
72 <servers>
73 <server>
74 <id>[email protected]</id>
75 <privateKey>path/to/private/key</privateKey>
76 <passphrase>private key passphrase</passphrase>
77 </server>
78 <server>
79
80 Examples
81 ____
82
83 changelog
84
85 mvn org.apache.maven.plugins:maven-scm-plugin:${project.version}:changelog
86
87 release
88
89 mvn release:prepare release:perform -Dresume=false -Dusername=XXX -Dpassword=XXX
90
91
92 Committer / Author
93 ____
94
95 The jgit provider per default uses the information of the "user" section in the .gitconfig. If you explicitly configure a user there, this user will be used as author and committer.
96 If you don't define a user in the .gitconfig, then the user passed as "username" with the maven execution is used. The email per default will be 'username'@hostname. If you don't like
97 the hostname to be used as the domain. you can configure a default domain in the .gitconfig as follows:
98
99 git config --global maven-scm.maildomain mycomp.com
100
101 You can also enforce the usage of the "username" for the author and committer (omit the default in the .gitconfig):
102
103 git config --global maven-scm.forceUsername true
104
105
106
107
108 Features
109 ---
110
111 this is a brief list of the supported maven-scm-provider-jgit's integration status with regard to some core maven plugins
112
113
114 maven-scm-plugin
115 ---
116
117 | goal | implemented?|
118 | ------------- |:-------------:|
119 | scm:list | yes |
120 | scm:tag | yes |
121 | scm:bootstrap | no |
122 | scm:export | no |
123 | scm:update | no |
124 | scm:status | yes |
125 | scm:edit | no |
126 | scm:changelog | yes |
127 | scm:add | yes |
128 | scm:unedit | no |
129 | scm:validate | yes |
130 | scm:branch | yes |
131 | scm:checkin | yes |
132 | scm:checkout | yes |
133 | scm:diff | yes |
134 | scm:blame | yes |
135 | scm:remoteinfo | yes |
136
137 maven-release-plugin
138 ---
139
140 | goal | implemented?|
141 | ------------- |:-------------:|
142 | release:clean | yes |
143 | release:prepare | yes |
144 | release:rollback | no |
145 | release:perform | yes |
146 | release:stage | no |
147 | release:branch | yes |