From 57dd39c9695a52b5d2f8012af064aad1eec68787 Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Tue, 6 Jun 2006 05:44:43 +0000 Subject: [PATCH] Autogenerated man pages for v1.4.0-rc1 --- man1/git-p4import.1 | 158 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 158 insertions(+) create mode 100755 man1/git-p4import.1 diff --git a/man1/git-p4import.1 b/man1/git-p4import.1 new file mode 100755 index 000000000..09921449f --- /dev/null +++ b/man1/git-p4import.1 @@ -0,0 +1,158 @@ +.\"Generated by db2man.xsl. Don't modify this, modify the source. +.de Sh \" Subsection +.br +.if t .Sp +.ne 5 +.PP +\fB\\$1\fR +.PP +.. +.de Sp \" Vertical space (when we can't use .PP) +.if t .sp .5v +.if n .sp +.. +.de Ip \" List item +.br +.ie \\n(.$>=3 .ne \\$3 +.el .ne 3 +.IP "\\$1" \\$2 +.. +.TH "GIT-P4IMPORT" 1 "" "" "" +.SH NAME +git-p4import \- Import a Perforce repository into git +.SH "SYNOPSIS" + + +git\-p4import [\-q|\-v] [\-\-authors ] [\-t ] + + +git\-p4import \-\-stitch + + +git\-p4import + +.SH "DESCRIPTION" + + +Import a Perforce repository into an existing git repository\&. When a and are specified a new branch with the given name will be created and the initial import will begin\&. + + +Once the initial import is complete you can do an incremental import of new commits from the Perforce repository\&. You do this by checking out the appropriate git branch and then running git\-p4import without any options\&. + + +The standard p4 client is used to communicate with the Perforce repository; it must be configured correctly in order for git\-p4import to operate (see below)\&. + +.SH "OPTIONS" + +.TP +\-q +Do not display any progress information\&. + +.TP +\-v +Give extra progress information\&. + +.TP +\-\-authors +Specify an authors file containing a mapping of Perforce user ids to full names and email addresses (see Notes below)\&. + +.TP +\-\-stitch +Import the contents of the given perforce branch into the currently checked out git branch\&. + +.TP +\-\-log +Store debugging information in the specified file\&. + +.TP +\-t +Specify that the remote repository is in the specified timezone\&. Timezone must be in the format "US/Pacific" or "Europe/London" etc\&. You only need to specify this once, it will be saved in the git config file for the repository\&. + +.TP + +The Perforce path that will be imported into the specified branch\&. + +.TP + +The new branch that will be created to hold the Perforce imports\&. + +.SH "P4 CLIENT" + + +You must make the p4 client command available in your $PATH and configure it to communicate with the target Perforce repository\&. Typically this means you must set the "$P4PORT" and "$P4CLIENT" environment variables\&. + + +You must also configure a p4 client "view" which maps the Perforce branch into the top level of your git repository, for example: + +.nf +Client: myhost + +Root: /home/sean/import + +Options: noallwrite clobber nocompress unlocked modtime rmdir + +View: + //public/jam/\&.\&.\&. //myhost/jam/\&.\&.\&. +.fi + + +With the above p4 client setup, you could import the "jam" perforce branch into a branch named "jammy", like so: + +.nf +$ mkdir \-p /home/sean/import/jam +$ cd /home/sean/import/jam +$ git init\-db +$ git p4import //public/jam jammy +.fi + +.SH "MULTIPLE BRANCHES" + + +Note that by creating multiple "views" you can use git\-p4import to import additional branches into the same git repository\&. However, the p4 client has a limitation in that it silently ignores all but the last "view" that maps into the same local directory\&. So the following will \fInot\fR work: + +.nf +View: + //public/jam/\&.\&.\&. //myhost/jam/\&.\&.\&. + //public/other/\&.\&.\&. //myhost/jam/\&.\&.\&. + //public/guest/\&.\&.\&. //myhost/jam/\&.\&.\&. +.fi + + +If you want more than one Perforce branch to be imported into the same directory you must employ a workaround\&. A simple option is to adjust your p4 client before each import to only include a single view\&. + + +Another option is to create multiple symlinks locally which all point to the same directory in your git repository and then use one per "view" instead of listing the actual directory\&. + +.SH "TAGS" + + +A git tag of the form p4/xx is created for every change imported from the Perforce repository where xx is the Perforce changeset number\&. Therefore after the import you can use git to access any commit by its Perforce number, eg\&. git show p4/327\&. + + +The tag associated with the HEAD commit is also how git\-p4import determines if their are new changes to incrementally import from the Perforce repository\&. + + +If you import from a repository with many thousands of changes you will have an equal number of p4/xxxx git tags\&. Git tags can be expensive in terms of disk space and repository operations\&. If you don't need to perform further incremental imports, you may delete the tags\&. + +.SH "NOTES" + + +You can interrupt the import (eg\&. ctrl\-c) at any time and restart it without worry\&. + + +Author information is automatically determined by querying the Perforce "users" table using the id associated with each change\&. However, if you want to manually supply these mappings you can do so with the "\-\-authors" option\&. It accepts a file containing a list of mappings with each line containing one mapping in the format: + +.nf + perforce_id = Full Name +.fi + +.SH "AUTHOR" + + +Written by Sean Estabrooks + +.SH "GIT" + + +Part of the \fBgit\fR(7) suite + -- 2.26.2