summaryrefslogtreecommitdiffstats
path: root/man1/git-init.1
diff options
context:
space:
mode:
Diffstat (limited to 'man1/git-init.1')
-rw-r--r--man1/git-init.171
1 files changed, 41 insertions, 30 deletions
diff --git a/man1/git-init.1 b/man1/git-init.1
index d2c98e510..456a60436 100644
--- a/man1/git-init.1
+++ b/man1/git-init.1
@@ -2,12 +2,12 @@
.\" Title: git-init
.\" Author: [FIXME: author] [see http://www.docbook.org/tdg5/en/html/author]
.\" Generator: DocBook XSL Stylesheets vsnapshot <http://docbook.sf.net/>
-.\" Date: 2024-03-18
+.\" Date: 2024-03-21
.\" Manual: Git Manual
-.\" Source: Git 2.44.0.279.g3bd955d269
+.\" Source: Git 2.44.0.325.g11c821f2f2
.\" Language: English
.\"
-.TH "GIT\-INIT" "1" "2024\-03\-18" "Git 2\&.44\&.0\&.279\&.g3bd955" "Git Manual"
+.TH "GIT\-INIT" "1" "2024\-03\-21" "Git 2\&.44\&.0\&.325\&.g11c821" "Git Manual"
.\" -----------------------------------------------------------------
.\" * Define some portability stuff
.\" -----------------------------------------------------------------
@@ -47,7 +47,7 @@ If the \fB$GIT_DIR\fR environment variable is set then it specifies a path to us
.sp
If the object storage directory is specified via the \fB$GIT_OBJECT_DIRECTORY\fR environment variable then the sha1 directories are created underneath; otherwise, the default \fB$GIT_DIR/objects\fR directory is used\&.
.sp
-Running \fIgit init\fR in an existing repository is safe\&. It will not overwrite things that are already there\&. The primary reason for rerunning \fIgit init\fR is to pick up newly added templates (or to move the repository to another place if \-\-separate\-git\-dir is given)\&.
+Running \fBgit init\fR in an existing repository is safe\&. It will not overwrite things that are already there\&. The primary reason for rerunning \fBgit init\fR is to pick up newly added templates (or to move the repository to another place if \fB\-\-separate\-git\-dir\fR is given)\&.
.SH "OPTIONS"
.PP
\-q, \-\-quiet
@@ -64,11 +64,13 @@ environment is not set, it is set to the current working directory\&.
.PP
\-\-object\-format=<format>
.RS 4
-Specify the given object format (hash algorithm) for the repository\&. The valid values are
-\fIsha1\fR
+Specify the given object
+\fI<format>\fR
+(hash algorithm) for the repository\&. The valid values are
+\fBsha1\fR
and (if enabled)
-\fIsha256\fR\&.
-\fIsha1\fR
+\fBsha256\fR\&.
+\fBsha1\fR
is the default\&.
.sp
Note: At present, there is no interoperability between SHA\-256 repositories and SHA\-1 repositories\&.
@@ -78,7 +80,9 @@ Historically, we warned that SHA\-256 repositories may later need backward incom
.PP
\-\-ref\-format=<format>
.RS 4
-Specify the given ref storage format for the repository\&. The valid values are:
+Specify the given ref storage
+\fI<format>\fR
+for the repository\&. The valid values are:
.sp
.RS 4
.ie n \{\
@@ -122,7 +126,9 @@ If this is a reinitialization, the repository will be moved to the specified pat
.PP
\-b <branch\-name>, \-\-initial\-branch=<branch\-name>
.RS 4
-Use the specified name for the initial branch in the newly created repository\&. If not specified, fall back to the default name (currently
+Use
+\fI<branch\-name>\fR
+for the initial branch in the newly created repository\&. If not specified, fall back to the default name (currently
\fBmaster\fR, but this is subject to change in the future; the name can be customized via the
\fBinit\&.defaultBranch\fR
configuration variable)\&.
@@ -130,51 +136,55 @@ configuration variable)\&.
.PP
\-\-shared[=(false|true|umask|group|all|world|everybody|<perm>)]
.RS 4
-Specify that the Git repository is to be shared amongst several users\&. This allows users belonging to the same group to push into that repository\&. When specified, the config variable "core\&.sharedRepository" is set so that files and directories under
+Specify that the Git repository is to be shared amongst several users\&. This allows users belonging to the same group to push into that repository\&. When specified, the config variable
+\fBcore\&.sharedRepository\fR
+is set so that files and directories under
\fB$GIT_DIR\fR
-are created with the requested permissions\&. When not specified, Git will use permissions reported by umask(2)\&.
+are created with the requested permissions\&. When not specified, Git will use permissions reported by
+\fBumask(2)\fR\&.
.sp
The option can have the following values, defaulting to
-\fIgroup\fR
+\fBgroup\fR
if no value is given:
.PP
-\fIumask\fR (or \fIfalse\fR)
+umask, false
.RS 4
Use permissions reported by umask(2)\&. The default, when
\fB\-\-shared\fR
is not specified\&.
.RE
.PP
-\fIgroup\fR (or \fItrue\fR)
+group, true
.RS 4
Make the repository group\-writable, (and g+sx, since the git group may not be the primary group of all users)\&. This is used to loosen the permissions of an otherwise safe umask(2) value\&. Note that the umask still applies to the other permission bits (e\&.g\&. if umask is
-\fI0022\fR, using
-\fIgroup\fR
+\fB0022\fR, using
+\fBgroup\fR
will not remove read privileges from other (non\-group) users)\&. See
-\fI0xxx\fR
+\fB0xxx\fR
for how to exactly specify the repository permissions\&.
.RE
.PP
-\fIall\fR (or \fIworld\fR or \fIeverybody\fR)
+all, world, everybody
.RS 4
Same as
-\fIgroup\fR, but make the repository readable by all users\&.
+\fBgroup\fR, but make the repository readable by all users\&.
.RE
.PP
-\fI<perm>\fR
+<perm>
.RS 4
\fI<perm>\fR
is a 3\-digit octal number prefixed with \(oq0` and each file will have mode
\fI<perm>\fR\&.
\fI<perm>\fR
-will override users\(cq umask(2) value (and not only loosen permissions as
-\fIgroup\fR
+will override users\(cq\fBumask(2)\fR
+value (and not only loosen permissions as
+\fBgroup\fR
and
-\fIall\fR
+\fBall\fR
do)\&.
-\fI0640\fR
+\fB0640\fR
will create a repository which is group\-readable, but not group\-writable or accessible to others\&.
-\fI0660\fR
+\fB0660\fR
will create a repo that is readable and writable to the current user and group, but inaccessible to others (directories and executable files get their
\fBx\fR
bit from the
@@ -185,7 +195,7 @@ bit for corresponding classes of users)\&.
.sp
By default, the configuration flag \fBreceive\&.denyNonFastForwards\fR is enabled in shared repositories, so that you cannot force a non fast\-forwarding push into it\&.
.sp
-If you provide a \fIdirectory\fR, the command is run inside it\&. If this directory does not exist, it will be created\&.
+If you provide a \fI<directory>\fR, the command is run inside it\&. If this directory does not exist, it will be created\&.
.SH "TEMPLATE DIRECTORY"
.sp
Files and directories in the template directory whose name do not start with a dot will be copied to the \fB$GIT_DIR\fR after it is created\&.
@@ -270,7 +280,9 @@ $ git commit \fB(3)\fR
tab(:);
r lw(\n(.lu*75u/100u).
\fB1.\fR\h'-2n':T{
-Create a /path/to/my/codebase/\&.git directory\&.
+Create a
+\fB/path/to/my/codebase/\&.git\fR
+directory\&.
T}
\fB2.\fR\h'-2n':T{
Add all existing files to the index\&.
@@ -286,8 +298,7 @@ Everything below this line in this section is selectively included from the \fBg
.PP
init\&.templateDir
.RS 4
-Specify the directory from which templates will be copied\&. (See the "TEMPLATE DIRECTORY" section of
-\fBgit-init\fR(1)\&.)
+Specify the directory from which templates will be copied\&.
.RE
.PP
init\&.defaultBranch