]> git.ipfire.org Git - thirdparty/git.git/blame - Documentation/git-cvsexportcommit.txt
Merge branch 'maint'
[thirdparty/git.git] / Documentation / git-cvsexportcommit.txt
CommitLineData
5e0306ad 1git-cvsexportcommit(1)
79f6ac77 2======================
5e0306ad
ML
3
4NAME
5----
c3f0baac 6git-cvsexportcommit - Export a single commit to a CVS checkout
5e0306ad
ML
7
8
9SYNOPSIS
10--------
483bc4f0
JN
11'git cvsexportcommit' [-h] [-u] [-v] [-c] [-P] [-p] [-a] [-d cvsroot]
12 [-w cvsworkdir] [-W] [-f] [-m msgprefix] [PARENTCOMMIT] COMMITID
5e0306ad
ML
13
14
15DESCRIPTION
16-----------
17Exports a commit from GIT to a CVS checkout, making it easier
a6080a0a 18to merge patches from a git repository into a CVS repository.
5e0306ad 19
648ee550
RR
20Specify the name of a CVS checkout using the -w switch or execute it
21from the root of the CVS working copy. In the latter case GIT_DIR must
22be defined. See examples below.
5e0306ad 23
a6080a0a
JH
24It does its best to do the safe thing, it will check that the files are
25unchanged and up to date in the CVS checkout, and it will not autocommit
5e0306ad
ML
26by default.
27
28Supports file additions, removals, and commits that affect binary files.
29
ba020ef5 30If the commit is a merge commit, you must tell 'git-cvsexportcommit' what
483bc4f0 31parent the changeset should be done against.
5e0306ad
ML
32
33OPTIONS
34-------
35
36-c::
37 Commit automatically if the patch applied cleanly. It will not
38 commit if any hunks fail to apply or there were other problems.
39
40-p::
1b91abe3 41 Be pedantic (paranoid) when applying patches. Invokes patch with
5e0306ad
ML
42 --fuzz=0
43
1b91abe3
ML
44-a::
45 Add authorship information. Adds Author line, and Committer (if
46 different from Author) to the message.
47
4a6b9bb6
SS
48-d::
49 Set an alternative CVSROOT to use. This corresponds to the CVS
50 -d parameter. Usually users will not want to set this, except
51 if using CVS in an asymmetric fashion.
52
992793c8
ML
53-f::
54 Force the merge even if the files are not up to date.
55
ca28370a
SS
56-P::
57 Force the parent commit, even if it is not a direct parent.
58
992793c8 59-m::
a6080a0a 60 Prepend the commit message with the provided prefix.
992793c8
ML
61 Useful for patch series and the like.
62
e5d80641 63-u::
db218723 64 Update affected files from CVS repository before attempting export.
e5d80641 65
648ee550
RR
66-w::
67 Specify the location of the CVS checkout to use for the export. This
68 option does not require GIT_DIR to be set before execution if the
325abb7b
TP
69 current directory is within a git repository. The default is the
70 value of 'cvsexportcommit.cvsdir'.
648ee550 71
d775734c
JS
72-W::
73 Tell cvsexportcommit that the current working directory is not only
74 a Git checkout, but also the CVS checkout. Therefore, Git will
75 reset the working directory to the parent commit before proceeding.
76
5e0306ad
ML
77-v::
78 Verbose.
79
325abb7b
TP
80CONFIGURATION
81-------------
82cvsexportcommit.cvsdir::
83 The default location of the CVS checkout to use for the export.
84
1506fc34
ML
85EXAMPLES
86--------
87
88Merge one patch into CVS::
89+
90------------
91$ export GIT_DIR=~/project/.git
92$ cd ~/project_cvs_checkout
b1889c36 93$ git cvsexportcommit -v <commit-sha1>
562e35c3 94$ cvs commit -F .msg <files>
1506fc34
ML
95------------
96
648ee550
RR
97Merge one patch into CVS (-c and -w options). The working directory is within the Git Repo::
98+
99------------
b1889c36 100 $ git cvsexportcommit -v -c -w ~/project_cvs_checkout <commit-sha1>
648ee550
RR
101------------
102
4c7100a9 103Merge pending patches into CVS automatically -- only if you really know what you are doing::
1506fc34
ML
104+
105------------
106$ export GIT_DIR=~/project/.git
107$ cd ~/project_cvs_checkout
b1889c36 108$ git cherry cvshead myhead | sed -n 's/^+ //p' | xargs -l1 git cvsexportcommit -c -p -v
1506fc34
ML
109------------
110
5e0306ad
ML
111Author
112------
648ee550 113Written by Martin Langhoff <martin@catalyst.net.nz> and others.
5e0306ad
ML
114
115Documentation
116--------------
648ee550 117Documentation by Martin Langhoff <martin@catalyst.net.nz> and others.
5e0306ad
ML
118
119GIT
120---
9e1f0a85 121Part of the linkgit:git[1] suite