forked from FiloSottile/gvt
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathalldocs.go
121 lines (86 loc) · 3.24 KB
/
alldocs.go
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
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
// DO NOT EDIT THIS FILE.
//go:generate gvt help documentation
/*
gvt, a simple go vendoring tool based on gb-vendor.
Usage:
gvt command [arguments]
The commands are:
fetch fetch a remote dependency
restore restore dependencies from manifest
update update a local dependency
list list dependencies one per line
delete delete a local dependency
Use "gvt help [command]" for more information about a command.
Fetch a remote dependency
Usage:
gvt fetch [-branch branch] [-revision rev | -tag tag] [-precaire] [-no-recurse] [-t|-a] importpath
fetch vendors an upstream import path.
Recursive dependencies are fetched (at their master/tip/HEAD revision), unless they
or their parent package are already present.
If a subpackage of a dependency being fetched is already present, it will be deleted.
The import path may include a url scheme. This may be useful when fetching dependencies
from private repositories that cannot be probed.
Flags:
-t
fetch also _test.go files and testdata.
-a
fetch all files and subfolders, ignoring ONLY .git, .hg and .bzr.
-branch branch
fetch from the named branch. Will also be used by gvt update.
If not supplied the default upstream branch will be used.
-no-recurse
do not fetch recursively.
-tag tag
fetch the specified tag.
-revision rev
fetch the specific revision from the branch or repository.
If no revision supplied, the latest available will be fetched.
-precaire
allow the use of insecure protocols.
Restore dependencies from manifest
Usage:
gvt restore [-precaire] [-connections N]
restore fetches the dependencies listed in the manifest.
It's meant for workflows that don't include checking in to VCS the vendored
source, for example if .gitignore includes lines like
vendor/**
!vendor/manifest
Note that such a setup requires "gvt restore" to build the source, relies on
the availability of the dependencies repositories and breaks "go get".
Flags:
-precaire
allow the use of insecure protocols.
-connections
count of parallel download connections.
Update a local dependency
Usage:
gvt update [ -all | importpath ]
update replaces the source with the latest available from the head of the fetched branch.
Updating from one copy of a dependency to another is ONLY possible when the
dependency was fetched by branch, without using -tag or -revision. It will be
updated to the HEAD of that branch, switching branches is not supported.
To update across branches, or from one tag/revision to another, you must first
use delete to remove the dependency, then fetch [ -tag | -revision | -branch ]
to replace it.
Flags:
-all
update all dependencies in the manifest.
-precaire
allow the use of insecure protocols.
List dependencies one per line
Usage:
gvt list [-f format]
list formats the contents of the manifest file.
Flags:
-f
controls the template used for printing each manifest entry. If not supplied
the default value is "{{.Importpath}}\t{{.Repository}}{{.Path}}\t{{.Branch}}\t{{.Revision}}"
Delete a local dependency
Usage:
gvt delete [-all] importpath
delete removes a dependency from the vendor directory and the manifest
Flags:
-all
remove all dependencies
*/
package main