-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathgit-get.1
More file actions
64 lines (64 loc) · 1.49 KB
/
git-get.1
File metadata and controls
64 lines (64 loc) · 1.49 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
.TH "GIT\-GET" "1" "2025-01-10" "https://github.com/stilvoid/git-get" "Git Manual"
.SH NAME
git-get \- clone a git repository into a folder structure derived from the repository URL
.SH SYNOPSIS
.B git-get
[\fB\-h\fR | \fB\-\-help\fR | \fB\-\-print\-path\fR | \fB\-\-location\fR \fIdir\fR]
.IR repository
[\fIargs\fR...]
.SH DESCRIPTION
.Nm
clones
.IR repository
into a folder derived from the repository URL by removing the scheme (e.g. \fIhttps://\fR),
the username (e.g. \fIgit@\fR),
and the suffix \fI.git\fR if it exists.
.SH OPTIONS
.TP
.B \-\-print\-path
Print the full path where the repository would be cloned and exit without cloning.
.TP
.B \-\-location \fIdir\fR
Override the base directory for this clone only.
.TP
.B \-h, \-\-help
Show help message and exit.
.PP
Any additional arguments are passed directly to the \fBgit clone\fR command.
.SH CONFIGURATION
You can override the default base path (\fI~/code\fR) with:
.PP
.RS
$ git config --global get.location "/path/to/your/code"
.RE
.SH EXAMPLES
.PP
Clone the git-get repository:
.PP
.nf
.RS
$ git get git@github.com:stilvoid/git-get
.RE
OR
.RS
$ git get https://github.com/stilvoid/git-get.git
.RE
.fi
.PP
will both result in the repository being checked out to
.PP
.RS
$HOME/code/github.com/stilvoid/git-get
.RE
.PP
Preview where a repository would be cloned:
.PP
.RS
$ git get --print-path https://github.com/stilvoid/git-get.git
.RE
.PP
Override the base directory for one clone:
.PP
.RS
$ git get --location ~/temp git@github.com:stilvoid/git-get.git
.RE