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
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
|
LAYMAN(8)
=========
:man source: layman {laymanversion}
:man manual: layman {laymanversion}
Brian Dolbec <dolsen@gentoo.org>
NAME
----
layman - manage your local repository of Gentoo overlays
SYNOPSIS
--------
*layman* (*-a*|*--add*) (*ALL*|'OVERLAY')
*layman* (*-d*|*--delete*) (*ALL*|'OVERLAY')
*layman* (*-D*|*--disable*) (*ALL*|'OVERLAY')
*layman* (*-E*|*--enable*) (*ALL*|'OVERLAY')
*layman* (*-f*|*--fetch*)
*layman* (*-i*|*--info*) (*ALL*|'OVERLAY')
*layman* (*-L*|*--list*)
*layman* (*-l*|*--list-local*)
*layman* (*-r*|*--readd*) (*ALL*|'OVERLAY')
*layman* (*-s*|*--sync*) (*ALL*|'OVERLAY')
*layman* (*-S*|*--sync-all*)
DESCRIPTION
-----------
*layman* is a script that allows you to add, remove, re-add,
update, disable, and then re-enable Gentoo overlays from a variety
of sources.
WARNING
~~~~~~~
*layman* makes it easy to retrieve and update overlays for Gentoo.
In addition it makes it TRIVIAL to break your system.
The Gentoo main tree provides you with high quality ebuilds that
are all maintained by Gentoo developers. This will not be the case
for most of the overlays you can get by using *layman*. Thus you
are removing the security shield that the standard tree provides
for you. You should keep that in mind when installing ebuilds from
an overlay.
To ensure the security of your system you MUST read the source of
the ebuild you are about to install.
OPTIONS
-------
ACTIONS
~~~~~~~
List of possible *layman* actions.
*-a* 'OVERLAY', *--add*='OVERLAY'::
Add the given overlay from the cached remote list to your
locally installed overlays. Specify "ALL" to add all overlays
from the remote list.
*-d* 'OVERLAY', *--delete*='OVERLAY'::
Remove the given overlay from your locally installed overlays.
Specify "ALL" to remove all overlays.
*-D* 'OVERLAY', *--disable*='OVERLAY'::
Disable the given overlay from portage. Specify "ALL" to disable
all installed overlays.
*-E* 'OVERLAY', *--enable*='OVERLAY'::
Re-enable a previously disabled overlay. Specify "ALL" to enable
all installed overlays.
*-f*, *--fetch*::
Fetches the remote list of overlays. You will usually NOT need
to explicitly specify this option. The fetch operation will be
performed automatically once you run the sync, sync-all, or list action.
You can prevent this automatic fetching using the *--nofetch* option.
*-i* 'OVERLAY', *--info*='OVERLAY'::
Display all available information about the specified overlay.
*-L*, *--list*::
List the contents of the remote list.
*-l*, *--list-local*::
List the locally installed overlays.
*-n*, *--nofetch*::
Prevents *layman* from automatically fetching the remote lists
of overlays. The default behavior for *layman* is to update all
remote lists if you run the sync, list or fetch operation.
*-p* 'LEVEL', *--priority*='LEVEL'::
Use this option in combination with the *--add*.
- make.conf::
It will modify the priority of the added overlay and thus influence
the order of entries in the make.conf file. The lower the priority,
the earlier in the list the entry will be mentioned in the make.conf.
- repos.conf::
It will modify the priority in the repos.conf file, and thus influence
the portage overlay priority. Read *man portage* for more details on
overlay priority.
Use a value between 0 and 100. The default value is 50.
*-r* 'OVERLAY', *--readd*='OVERLAY'::
Remove and re-add the given overlay from the cached
remote list to your locally installed overlays. Specify "ALL" to
re-add all local overlays.
*-s* 'OVERLAY', *--sync*='OVERLAY'::
Update the specified overlay. Use "ALL" as parameter to
synchronize all overlays.
*-S*, *--sync-all*::
Update all overlays. Shortcut for *-s ALL*.
PATH OPTIONS
~~~~~~~~~~~~~
List of available *layman* path options.
*-c* 'PATH', *--config*='PATH'::
Path to an alternative configuration file.
*-C* 'PATH', *--configdir*='PATH'::
Directory path for all layman configuration information.
*-o* 'URL', *--overlays*='URL'::
Specifies the location of additional overlay lists. You can use
this flag several times and the specified URLs will get temporarily
appended to the list of URLs you specified in your config file.
You may also specify local file URLs by prepending the path with
'file://'. This option will only append the URL for this specific
*layman* run - edit your config file to add a URL permanently.
So this is useful for testing purposes.
*-O* 'PATH', *--overlay_defs* 'PATH'::
Path to additional overlay.xml files.
OUTPUT OPTIONS
~~~~~~~~~~~~~~
List of *layman* output options.
*--debug-level* 'DEBUG_LEVEL'::
Outputs *layman* debugging information. The lower the debug level,
the less debugging information you'll get. Use a value between 0
and 10. 0 means no debugging information, 10 selects all debugging
messages. The default debug level is 4.
*-k*, *--nocheck*::
- When listing remote overlays (using *-L* or *--list*) *layman*
no longer hides overlays, for which you lack the tools to use.
By default, *layman* hides Git repositories if you do not have Git
installed. Same applies to Subversion, CVS and so forth.
- Prevents *layman* from checking the remote lists of overlays for
complete overlay definitions. The default behavior for *layman* is
to reject overlays that do not provide a description or a contact
attribute.
*-N*, *--nocolor*::
Remove color codes from the *layman* output.
*-q*, *--quiet*::
Makes *layman* completely quiet. In quiet mode child processes
will be run with stdin closed to avoid running into infinite and
blindly interactive sessions. Thus a child process may abort once
it runs into an situation with need for human interaction.
For example this might happen if your overlay resides in Subversion
and the SSL certificate of the server needs manual acceptance.
*-Q* 'LEVEL', *--quietness*='LEVEL'::
Makes *layman* less verbose. Choose a value between 0 and 4
with 0 being completely quiet. Once you set this below 3,
the same warning as given for *--quiet* applies.
*-v*, *--verbose*::
Makes *layman* more verbose and you will receive a description of
the overlays you can download.
*-W* 'WIDTH', *--width* 'WIDTH'::
Sets the screen width. This setting is usually not required as layman
is capable of detecting the available number of columns automatically.
ADDITIONAL OPTIONS
~~~~~~~~~~~~~~~~~~
*--protocol_filter* 'PROTOCOL'::
Sets the protocol filter that determines which protocols will be used
when adding overlays or updating their source URLs.
CONFIGURATION
-------------
*layman* reads configuration parameters from the file
'/etc/layman/layman.cfg' by default. This file provides seven possible
settings.
storage::
Directory that will be used to store the overlays and all
additional data *layman* needs. The default is '/var/lib/layman'.
*layman* uses a location within the '/usr/portage' hierarchy
instead of '/var' in order to store its data. This decision has
been made to support network file systems. If you have your
Gentoo tree on NFS or a similar file system and several
machines access the same ebuild repository over the net it
will be necessary to also provide all necessary *layman* data
within the hierarchy of the tree. This way the overlays will
also have to be synced at one location only.
cache::
*layman* will store the downloaded global list of overlays here.
The default is '%(storage)s/cache.xml'.
installed::
*layman* will store the list of installed overlays here.
The default is '%(storage)s/installed.xml'.
make.conf::
This is the *portage* configuration file that *layman* will
modify in order to make the new overlays available within
*portage*. The default is '%(storage)s/make.conf'. You could
also specify '/etc/portage/make.conf' directly. But that would mean
that you have an external program trying to automatically
set variables within this very central configuration file.
Since I consider that dangerous I prefer having a very small
external file that only contains the setting for
*PORTDIR_OVERLAY*. This file is then sourced at the end of
'/etc/portage/make.conf'. This is the reason why *layman* suggests running
the following *after* it has been installed.
echo 'source /var/lib/layman/make.conf' >> /etc/portage/make.conf
overlays::
Specifies the URL for the remote list of all available overlays.
The default is 'https://api.gentoo.org/overlays/repositories.xml'.
You can specify several URLs here (one per line). The contents will
get merged to a single list of overlays. This allows to add a personal
collection of overlays that are not present in the global list.
proxy::
Specify your proxy in case you have to use one.
nocheck::
Set to "yes" if *layman* should stop worrying about overlays
with missing a contact address or the description.
clean_archive::
Set to "yes" if *layman* will delete archive files downloaded
when installing archive type overlays. This option is only
applicable to remote archive overlays. *layman* will leave the
reponsibility of deleting local archive files up to the user.
By default, *layman* will delete downloaded archive files.
check_official::
Set to "no" if you don't want layman to prompt you for consent
during the installation of an unofficial overlay.
Per repository type Add, Sync options.
bzr_addopts::
bzr_syncopts::
cvs_addopts::
cvs_syncopts::
...::
These are a space separated list of command options to include in the commands sent to perform
the desired action.
Per repository type Post Add, Sync hooks.
bzr_postsync::
cvs_postsync::
darcs_postsync::
git_postsync::
...::
These are a space separated list of commands that are run after each add, sync operation if they
are defined.
DATABASE CONFIGURATION OPTIONS
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
*layman* now supports multiple database types for layman's install file. The
options allowed include: *xml*, *json*, and *sqlite*. While xml is the default
database type you may migrate from one database type to the other using the
*layman-updater* tool while supplying the *-m* flag, followed by the database
type you'd like to use.
REPO CONFIGURATION OPTIONS
~~~~~~~~~~~~~~~~~~~~~~~~~~
*layman* now accepts multiple repository config file options. One being the
already standard make.conf option and the other being the repos.conf files
that can be placed in /etc/portage/repos.conf/. The below configuration options
allow you to alter particular things regarding the repository configuration::
- conf_type::
Specifies the repo configuration type you wish to use. This can
be *repos.conf*, *make.conf*, or both separated by a comma. The
default value is *repos.conf*.
- require_repoconfig::
Defines whether a configuration file is needed for the package
manager or other multi-repository consumer application.
- repos_conf::
Specifies the path to the config file for all repos.conf
configuration. The default location is
'/etc/portage/repos.conf/layman.conf'.
- auto_sync::
"yes" or "no" value that defines whether or not you want your
layman overlays automatically synced by the portage sync plug-in
(requires repos.conf support).
HANDLING OVERLAYS
-----------------
*layman* intends to provide easy maintenance of Gentoo overlays
while not requiring any configuration.
OVERLAY LISTS
~~~~~~~~~~~~~
*layman* allows you to fetch an overlay without the need to modify
any configuration files. In order for this to be possible the script
needs an external list of possible overlay sources. There is a
centralized list available at
'https://api.gentoo.org/overlays/repositories.xml'
but nothing will prevent you from using or publishing your own
list of overlays. The location of the remote lists can also be
modified using the *--overlays* option when running *layman*.
To get a new overlay added to the central list provided for *layman*,
send a mail to <overlays@gentoo.org>. Gentoo developers may add their
overlay entries directly into the list which can be accessed over the
CVS repository for the Gentoo website.
You can also use several lists at the same time. Just add one URL per
line to the overlays variable in your configuration file. *layman*
will merge the contents of all lists.
*layman* also allows you to define local files in this list.
Just make sure you prepend these path names in standard URL notation with 'file://'.
*layman* also gives you the ability to just add an overlay definition to '/etc/layman/overlays/some-overlay.xml' and it will be automatically available for actions such as
add, delete, info... (see below for file format details)
If you need to use a proxy for access to the Internet, you can use
the corresponding variable in the *layman* configuration file.
*layman* will also respect the *http_proxy* environment variable in case you set it.
FILTERING PROTOCOL URLS
~~~~~~~~~~~~~~~~~~~~~~~
When adding an overlay or updating its source URL you can specify which
protocols you wish to use. Examples of this include http://, git://, and
https://.
To filter these protocols on a system-wide level you may alter the
protocol_filter variable in your *layman* configuration file.
Otherwise, you may specify which protocols you would prefer to be filtered out
on a per-run basis using the *--protocol_filter* flag.
Using this filtering will ensure that no other protocols other than the ones
specified will be used. Meaning that if an overlay does not support any of
the specified protocols, it will not install.
LOCAL CACHE
~~~~~~~~~~~
*layman* stores a local copy of the fetched remote list.
It will be stored in '/var/lib/layman/cache.xml' by default.
There exists only one such cache file and it will be overwritten
every time you run *layman*.
HANDLING /ETC/PORTAGE/MAKE.CONF
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Since *layman* is designed to automatically handle the inclusion of
overlays into your system it needs to be able to modify the
*PORTDIR_OVERLAY* variable in your '/etc/portage/make.conf' file.
But '/etc/portage/make.conf' is a very central and essential configuration
file for a Gentoo system. Automatically modifying this file would
be somewhat dangerous. You can allow *layman* to do this by
setting the make_conf variable in the configuration file to
'/etc/portage/make.conf'.
A much safer and in fact recommended solution to the problem is
to let *layman* handle an external file that only contains the
*PORTDIR_OVERLAY* variable and is sourced within the standard
'/etc/portage/make.conf' file. Just add the following line to the end of
your '/etc/portage/make.conf' file:
-------------------------------------------
source /var/lib/layman/make.conf
-------------------------------------------
'/var/lib/layman/make.conf' is the default provided in the *layman*
configuration. Change this file name in case you decide to store
it somewhere else.
The file does not necessarily need to exist at the beginning.
If it is missing, *layman* will create it for you.
There is also no need to remove the original *PORTDIR_OVERLAY*
variable from the make.conf file. Layman will simply add new overlays
to this variable and all your old entries will remain in there.
ADDING, REMOVING AND UPDATING OVERLAYS
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Once a remote list of overlays has been fetched, *layman* allows
to add overlays from the remote list to your system. The script
will try to fetch the overlay. If this is successful the overlay
information will be copied from the cache to the list of locally
installed overlays. In addition *layman* will modify the
*PORTDIR_OVERLAY* variable to include the new overlay path.
Removing the overlay with *layman* will delete the overlay without
leaving any traces behind.
In order to update all overlays managed by *layman* you can run
the script with the *--sync ALL* option or the *--sync-all* flag.
*NEW* DISABLING, AND RE-ENABLING OVERLAYS
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
portage will find installed overlays via your repo config files,
whether it be make.conf or repos.conf. If you wish to hide the
overlay from portage so that the ebuilds will not be accessible
then you can do so with the *--disable* 'OVERLAY' option. This
will then disable the overlay in your repo configurations.
To re-enable them again so that portage can again access the
ebuilds of that overlay you can simply do so with the
*--enable* 'OVERLAY' option.
LIST OVERLAYS
~~~~~~~~~~~~~
*layman* provides the *-L*, *--list* and *-l*, *--list-local* options to print
a list of available respectively installed overlays.
Listing will prepend all fully supported overlays with a green
asterisk, all non-official overlays with a yellow asterisk and
all overlays that you will not be able to use since you do not
have the necessary tools installed with a red asterisk.
In the default mode *layman* will be strict about listing overlays
and only present you with overlays that are fully supported.
In addition it will complain about overlays that are missing
a description field or a contact attribute. This type of behavior
has been added with *layman* 1.0.7 and if you'd like to return to
the old behavior you may use the k option flag or set the nocheck
option in the configuration file.
SEARCHING EBUILDS IN OVERLAYS
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
You can search through the ebuilds available in the overlays on
'http://overlays.gentoo.org/' by using *eix*. Emerge the package and
run:
update-eix-remote update
Alternatively, you can browse overlays that you have not installed
on 'http://gpo.zugaina.org/'.
OVERLAY TYPES
~~~~~~~~~~~~~
Currently *layman* supports overlays that are exported via *rsync*,
*CVS*, *subversion*, *bzr*, *darcs*, *git*, *mercurial*, *tar*
packages, or *squashfs* images that will be mounted read-only.
It also supports the generated overlay type *g-sorcery* installed with
the g-cran package (at time of this writing, only available in the science
overlay).
OVERLAY LISTS
-------------
OVERLAY LIST FORMAT
~~~~~~~~~~~~~~~~~~~
Layman uses a central list of overlays in XML format. The file looks
like this:
Example 1. An example overlays.xml file
-------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE repositories SYSTEM "/dtd/repositories.dtd">
<repositories xmlns="" version="1.0">
<repo quality="experimental" status="official">
<name>gnome</name>
<description>experimental gnome ebuilds</description>
<homepage>http://git.overlays.gentoo.org/gitweb/?p=proj/gnome.git;a=summary</homepage>
<owner type="project">
<email>gnome@gentoo.org</email>
<name>GNOME herd</name>
</owner>
<source type="git">git://git.overlays.gentoo.org/proj/gnome.git</source>
<source type="git">http://git.overlays.gentoo.org/gitroot/proj/gnome.git</source>
<source type="git">git+ssh://git@git.overlays.gentoo.org/proj/gnome.git</source>
<feed>http://git.overlays.gentoo.org/gitweb/?p=proj/gnome.git;a=atom</feed>
<feed>http://git.overlays.gentoo.org/gitweb/?p=proj/gnome.git;a=rss</feed>
</repo>
</repositories>
-------------------------------------------
Example 2. An example overlays.xml file with a branch
-------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE repositories SYSTEM "/dtd/repositories.dtd">
<repositories xmlns="" version="1.0">
<repo quality="experimental" status="official">
<name><hardened-development></name>
<description><Development Overlay for Hardened Gcc 4.x Toolchain></description>
<homepage>http://git.overlays.gentoo.org/gitweb/?p=proj/hardened-dev.git;a=summary</homepage>
<owner type="project">
<email>hardened@gentoo.org</email>
</owner>
<source type="git" branch="uclibc">git://git.overlays.gentoo.org/proj/hardened-dev.git</source>
<feed>http://git.overlays.gentoo.org/gitweb/?p=proj/hardened-dev.git;a=atom</feed>
</repo>
</repositories>
--------------------------------------------
Users can specify a branch for an overlay, given one actually exists.
This logic is applicable to CVS overlays as well and the branch variable
is comparable to specifying a subpath for a CVS repository.
VCS types where the use of "branch" is supported is as follows::
- CVS
- Squashfs
- Tar
- Git
- Mercurial
However, for CVS, Squashfs, and Tar overlays, the branch will be treated as a
subpath. If you use the branch variable with any other overlay types aside from
the ones listed, it will be ignored.
ADDING AN OVERLAY LOCALLY
~~~~~~~~~~~~~~~~~~~~~~~~~
Simply create an overlay list in the format described above and run
*layman* with the -o switch. You need to prepend local file URLs
with 'file://'. *New* is the ability to just add an overlay definition like
the above to /etc/layman/overlays/some-overlay.xml and it will be
automatically available for actions such as add, delete, info...
ADDING AN OVERLAY GLOBALLY
~~~~~~~~~~~~~~~~~~~~~~~~~~
The global list of overlays used by *layman* lies at
'https://api.gentoo.org/overlays/repositories.xml'.
All Gentoo developers have access to this location via CVS and
can modify the list of overlays.
If you are not a Gentoo developer but wish to get your overlay
listed you should contact the Gentoo Overlays team at
<overlays@gentoo.org>. You can also join *#gentoo-overlays* on
irc.freenode.net.
EXAMPLES
--------
INSTALLING AN OVERLAY
~~~~~~~~~~~~~~~~~~~~~
-------------------------------------------
layman -f -a wrobel
-------------------------------------------
This would add the overlay with the id wrobel to your list of
installed overlays.
SYNCING YOUR OVERLAYS
~~~~~~~~~~~~~~~~~~~~~
-------------------------------------------
layman -s ALL
-------------------------------------------
This updates all overlays
PERFORMING SEVERAL ACTIONS AT THE SAME TIME
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-------------------------------------------
layman -f -a wrobel webapps-experimental
-------------------------------------------
This fetches the remote list and immediately adds two overlays
FILES
-----
'/etc/layman/layman.cfg'::
Configuration file, holding the defaults for *layman*
'/var/lib/layman/make.conf'::
Configuration file that layman modifies to
register the installed overlay(s) with the package manager
'/etc/portage/repos.conf/layman.conf'::
Configuration file that layman modifies to
register the installed overlay(s) with the package manager
AUTHORS
-------
- Gunnar Wrobel <wrobel@gentoo.org> (original, retired)
- Sebastian Pipping <sping@gentoo.org>
- Brian Dolbec <brian.dolbec@gmail.com>
- Devan Franchini <twitch153@gentoo.org>
REPORTING BUGS
--------------
Please report bugs you might find at 'http://bugs.gentoo.org/'. Thank you!
SEE ALSO
--------
make.conf(5), eix(1), portage(5)
|