forked from aurutils/aurutils
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathaur.1
260 lines (198 loc) · 5.29 KB
/
aur.1
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
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
'\" t
.TH AUR 1 2016-12-25 AURUTILS
.SH NAME
aur \- helper tool for the arch user repository
.SH PROGRAMS
The below gives a short overview; see the respective documentation for
details.
.P
.BR aur-build (1)
.RS 4
Build packages to a local repository.
.RE
.P
.BR aur-deps (1)
.RS 4
Order package dependencies.
.RE
.P
.BR aur-fetch (1)
.RS 4
Retrieve build files from the AUR.
.RE
.P
.BR aur-pkglist (1)
.RS 4
Print the AUR package list.
.RE
.P
.BR aur-rfilter (1)
.RS 4
Filter packages in the Arch Linux repositories.
.RE
.P
.BR aur-search (1)
.RS 4
Search for AUR packages.
.RE
.P
.BR aur-srcver (1)
.RS 4
Update and print package revisions.
.RE
.P
.BR aur-sync (1)
.RS 4
Download and build AUR packages automatically
.RE
.P
.BR aur-vercmp (1)
.RS 4
Check packages for AUR updates.
.RE
.SH EXIT STATUS
Programs follow a subset of errno(3), or preserve command status where
applicable.
.P
See also EXIT STATUS in wget(1).
.SH CREATING A LOCAL REPOSITORY
Configure the local repository in a separate pacman configuration,
for example in \fI/etc/pacman.d/custom\fR:
.EX
[options]
CacheDir = /var/cache/pacman/pkg
CacheDir = /var/cache/pacman/custom
CleanMethod = KeepCurrent
[custom]
SigLevel = Optional TrustAll
Server = file:///var/cache/pacman/custom
.EE
Avoid naming the repository \fIlocal\fR, as this name is reserved by
pacman.
.P
Include the configuration in \fI/etc/pacman.conf\fR:
.EX
# An example of a custom package repository. See the pacman manpage for
# tips on creating your own repositories.
Include = /etc/pacman.d/custom
.EE
Add \fIInclude \fRto the \fBend \fRof pacman.conf, where possible.
.P
Create the repository root and database:
.EX
$ sudo install -d /var/cache/pacman/custom -o $USER
$ repo-add /var/cache/pacman/custom/custom.db.tar
.EE
If packages are already available, add them to the database:
.EX
$ cd /var/cache/pacman/custom
$ repo-add -n custom.db.tar ./*.pkg.tar.xz
.EE
Synchronize pacman:
.EX
$ sudo pacman -Syu
.EE
.SY Note:
It is recommended to use a pacman cache directory (\fICacheDir\fR) as
the package pool. This avoids checksum mismatches between built
packages and any cached versions.
.YS
.SY Tip:
Consider separate repositories for different purposes, such as
version control packages.
.YS
.SH MIGRATING FOREIGN PACKAGES
If built packages are available, follow the instructions in
\fBCreating a local repository\fR and move the packages to the new
location.
Missing packages may be recreated from system files. Before doing so,
it is recommended to check for mismatches between the pacman database
and the local filesystem:
.EX
$ pacman -Qqm | paccheck --md5sum --quiet
.EE
If mismatches occur, consider rebuilding the respective
packages. Otherwise, recreate the packages with \fIbacman\fR:
.EX
$ pacman -Qqm | xargs -L1 bacman
.EE
Results will be saved to \fIPKGDEST\fR, or to the current directory if
this variable is not set.
.SH EXAMPLES
Examples below assume \fIbash\fR as the interactive shell.
Run actions on the dependency tree of an AUR package:
.EX
$ aur deps foobar | while read -r pkg; do ... done
.EE
Build all packages in the \fIpkgbuilds\fR github repository: (requires
\fIpkgbuild-introspection\fR)
.EX
$ git clone https://www.github.com/Earnestly/pkgbuilds
$ cd pkgbuilds
$ find -maxdepth 2 -name PKGBUILD -execdir mksrcinfo \\;
$ aur deps -s ./* > queue # Remove unwanted targets
$ aur build -d custom -a queue
.EE
Print packages from the \fIcustom\fR repository that are not available
in the AUR:
.EX
$ grep -Fxvf <(aur pkglist) <(pacman -Slq custom)
.EE
As above, but for orphaned packages:
.EX
$ pacman -Slq custom | aur rpc -t info | \\
jq -r '.[].results[] | select(.Maintainer == null)'
.EE
Print Perl modules that are both in the AUR and official repositories:
.EX
$ aur pkglist -P '^perl-.+' > perl.txt
$ grep -Fxvf <(aur rfilter < perl.txt) perl.txt
.EE
Search for packages with both 'wm' and 'git' in the name:
.EX
$ aur pkglist -P '(?=.*wm)(?=.*git)' | xargs aur search -i
.EE
Build \fIplasma-desktop-git\fR and its dependencies in an nspawn container:
.EX
$ aur sync -c plasma-desktop-git
.EE
Update all AUR packages in a single local repository:
.EX
$ aur sync -u
.EE
Update packages from the \fIcustom\fR repository that are installed on the host:
.EX
$ aur sync --repo=custom $(grep -Fxf <(pacman -Qq) <(pacman -Slq custom))
.EE
Build a package for a different architecture, here \fIi686\fR:
.EX
$ setarch i686 aur sync -c --repo=custom_i686 tclkit
.EE
Select a package matching \fIpony\fR and build the result:
.EX
$ select a in $(aur pkglist -F pony); do aur sync "$a"; break; done
.EE
Print packages both in AUR and [community] and compare their versions:
.EX
$ aur vercmp -d community -a
.EE
Check foreign packages for AUR updates:
.EX
$ pacman -Q | aur vercmp
.EE
Repository packages can be "made foreign" by temporarily removing the
repository from the pacman configuration. This can be used with programs
that only check foreign packages for AUR updates.
For example, create the following script in
\fI/usr/local/bin/mypacman\fR:
.EX
#!/bin/sh
pacman --config=/usr/share/devtools/pacman-extra.conf "$@"
.EE
This script can then be propagated through the \fIPACMAN\fR variable
for programs supporting it.
.SH AUTHORS
.MT https://github.com/AladW
Alad Wenter
.ME
.\" vim: set textwidth=72