C. Command-Line Reference : config-repo
   
config-repo
configure a repo
Usage
gitcentric config-repo [--server <server>:<port>] [--noNotify] [--clear]
[--useAccuworkKey | --useThirdPartyKey] [--cpkPattern <regex>]
[--user <user>] [--pw <password>][--help] [--children-of <reponame>] [<reponame>...] [--]
Description
The gitcentric config_repo command enables you to configure Git repositories for use with GitCentric.
Specify one or more repositories to configure with <reponame>....
You can use the --useAccuworkKey or --useThirdPartyKey options to configure a repo for an AccuRev server that uses either AccuWork or a third-party issue tracking system. For more information, see Enable and Use Change Packages on page 43.
If your site does use change packages, the --cpkPattern option can be used to specify a Regular Expression setting that determines what your users need to put in their Git commit comments so that AccuRev knows what issue the change applies to. A discussion of Java regular expressions is beyond the scope of this document, but here is an example:
Resolved\s+([\d,]+) -- This format would be adequate for simple environments where the comment always starts with “Resolved”, followed by white space, followed by any number of issues, separated by commas:
Resolved 12576
Resolved 34, 149, 11057, 686
Note: White space in regular expressions (and any other CLI argument) needs to be quoted (see Spaces and Quoting on page 89), and special characters may require escape characters or quoting. For example, for the above regular expression to be passed correctly from the command line, you would need to construct the option as follows: --cpkPattern "Resolved'\'s+['\'d,]+)"
Use a search engine and search for “Java regular expressions” for more information about these formats.
Options
--children-of <reponame>
Configure all the children of the specified parent repo.
--clear
Clear out all GitCentric configuration for this repository, including ALL branch configuration.
--cpkPattern, -c <regex>
Specify an AccuRev change package regular expression that determines what your users need to put in their Commit comments so that AccuRev knows what issue the change applies to.
--help, -h
Display the help for this command.
--noNotify
Do not notify the GitCentric bridge of the configuration change. This is useful if you are making a series of configuration changes and do not want commit them until they are all done, by omitting --noNotify on the last command. If you forget to omit --noNotify on the last command, you can force the commit by either executing a config-repo or config-branch command, or by restarting the bridge (such as through the Tomcat admin console).
--pw, -p <password>
The AccuRev login password for <user>. If omitted then an empty password is used to log in to AccuRev.
--server, -S <server>:<port>
Specify the IP address and the port to the AccuRev server that this repository is mapped to.
--useAccuworkKey, -a,
--useThirdPartyKey, -3,
Use Accuwork issue numbers for change packages, or use third party ITS keys instead of AccuWork issue numbers for change packages. These options are mutually exclusive.
--user, -u <user>
The AccuRev login account to use for this repository.
--
"End-of-options" marker. See Basic Syntax on page 89 for more details.
Examples

Initial configuration example: Configure a repo named "proj_3000" to be associated with the AccuRev server at "myACServer:5050", which uses ASSIGN_PRIVILEGE_USER "agc_sync" with a password of "sync001":
> >ssh -p 29418 mylogin@myGCserver gitcentric config-repo proj_3000
-S myACServer:5050 -u agc_sync -p sync001
Maintenance example: Change repos "proj_3000" and "proj_4000", as well as all of the immediate children of parent-only repo "off_shore_parent" to a new server (which uses the same ASSIGN_USER_PRIVILEGE user and password).
> >ssh -p 29418 mylogin@myGCserver gitcentric config-repo proj_3000 proj_4000
--children-of off_shore_parent -S myACServer:5050 -u agc_sync -p sync001
Access
Any member of the Project-Owners or Administrators groups.
See Also
Basic Syntax on page 89, delete-repo, config-branch, ls-repo