summaryrefslogtreecommitdiff
path: root/doc/update-menus.1
blob: 48586e37d9ce6e1a84186f9bd74809177fc6d207 (plain)
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
.\" -*- nroff -*-
.TH UPDATE-MENUS 1 "Debian Utilities" "DEBIAN"
.SH NAME
update-menus \- generate Debian menu system
.SH SYNOPSIS
.B update-menus [\-v] [\-d] [\-h|--help] [--version] [--menufilesdir <dir>] [--menumethod <method>] [--nodefaultdirs] [--stdout]
.SH DESCRIPTION
Before the advent of \fIupdate-menus\fP, when the system administrators installed a 
package onto a Debian system, they would need to edit various window 
manager configuration files to make the new program show up on, for example, 
fvwm's menus. The menus could easily become out of sync with what programs
were actually available, with some menu items that didn't work, and other
programs that lacked a menu entry.
.I update-menus
and Debian's menu package aim to solve this problem.
.PP
.I update-menus 
automatically generates menus of installed programs for window 
managers and other menu programs. It should be run whenever a
.BR menufile (5)
or menu-method file is changed.
.I update-menus
will be run automatically when Debian packages that contain menu 
files are installed on or removed from the system.
.PP
.I update-menus
uses the package-supplied menu entry files (in /usr/share/menu) for
its information about the menus (but this can be overruled by the
system administrator/user; see below). If a menu entry file is executable,
.I update-menus
executes the menu entry file, and uses its stdout to generate the menu
database.

.SH OPTIONS
.IP "-v"
Verbose output. Shows all arguments to the /etc/menu-methods programs.
.IP "-d"
Debug output. Generates loads of unintelligible output.
.IP "-h, --help"
Display usage help and exit.
.IP "--menufilesdir <dir>" 
Adds directory <dir> to the list of directories to search for menu files in. 
.IP "--menumethod <method>" 
Process only the menu method <method> instead of all the menu methods found.
.IP "--nodefaultdirs"
Disables the search of menu entries in system menu directories.
.IP "--nodpkgcheck"
Do not discard menu entries for packages that are not installed according to
\fIdpkg\fP.
.IP "--remove"
Remove the menus by calling the menu-methods with \fB--remove\fP.
.IP "--stdout" 
Output the menu list in a format suitable as input for \fIinstall-menu\fP or a
menu method file.
.IP "--version"
Output version information and exit.
.SH CONFIGURATION
There are several ways to tune the operation of update-menus:
.PP
.I per menu entry, in /etc/menu/$package
.RS
In these directories the system administrator or user can override the default
menu files (If a file /etc/menu/$package exists, than the
corresponding /usr/share/menu/$package file isn't read any more). Users
who want to override the system wide defaults put their files in
~/.menu. See also 
.BR menufile(5)
.RE
.I per window-manager in /etc/menu-methods/$wm
.RS
In these configuration files, one can tune generated system.${wm}rc files for
each individual window manager. For example, one can specify that the
wm should ignore any icons that the packages may supply, or set the
default wrapper for text-only applications (usually, an xterm is started to
run a text-only application like vi). Users who want to override the system
wide defaults put their files in ~/.menu-methods. For more info, see
/usr/share/doc/menu/html. 
.RE
.I globally, in /etc/menu-methods/translate_menus
.RS
This file contains translations that will be performed for all
menu entries and all window managers. You can specify things like:
`All sections that start with "Games" should be mapped to "Applications/Games"',
or `menuentry "gnuplot" should have a title of "GnuTeken"'. Look at the 
default /etc/menu-methods/translate_menus for an example. Users who want to
override the system default translate file, put one in
~/.menu-methods/translate_menus. 
.BR Note:
This should not be used for a full translation of the menu. Use po
files as explained in the source package.
.RE
.I error report configuring, in /etc/menu-methods/menu.config
.RS
This file contains general information for the overall behaviour of
update-menus. At the moment you can only configure how verbose the
output of update-menus is, and where it sends the output. The amount
of information is specified by `verbosity=VAL'. Use VAL=quiet to stop
update-menu from reporting anything but the most important errors,
VAL=normal, VAL=verbose, VAL=debug for progressively more output.

To specify where the output should go, use `method=stdout',
`method=stderr', or `method=syslog facility priority'. `Facility' is one
of auth, authpriv, authcron, authdaemon, authkern, authlocal0, authlocal1,
authlocal2, authlocal3, authlocal4, authlocal5, authlocal6, authlocal7,
authlpr, authmail, authnews, authsyslog, authuser,
authuucp. `priority' is one of emerg, alert, crit, err, warning,
notice, info, debug.

.RE
.SH FILES
Menu files: (Earlier listed directories override those listed later.)
.RS
.I ~/.menu/*
.RS
Menu files added by the user. (Isn't read if root runs update-menus)
.RE
.I /etc/menu/*
.RS
Menu files added by the system administrator.
.RE
.I /usr/lib/menu/*
.RS
Architecture-dependant menu files provided by other Debian packages.
.RE
.I /usr/share/menu/*
.RS
Architecture-independant menu files provided by other Debian packages.
.RE
.I /usr/share/menu/default/*
.RS
Menu files provided by the menu package. 
.RE
.RE
Menu methods:
.RS
.I /etc/menu-methods/
.RS
Executable configuration files that are added by window managers and other menu
programs, these files are run by
.I update-menus
to generate menus for the different programs. Also in this directory
is the translate_menus file, used for local configuration of the shape of the
menu trees.
.RE
.RE
.RS
.I ~/.menu-methods/
.RS
For users to override the system-defaults of /etc/menu-methods.
If this directory exists, no files in /etc/menu-methods are read
any more.
.RE
.RE
.SH DISTRIBUTION
Distribution is subject to the GNU General Public License.
.SH BUGS
.I update-menus
may not work properly when run by a normal user, to generate menus for that
user. This is usually because the window manager doesn't expect the
system.${wm}rc files in the directory (usually ~/.${wm}, configurable
in /etc/menu-methods). If you see such a thing, and you find a
solution, please mail <menu@packages.debian.org>. It should work OK for
fvwm and fvwm2: I usually test the package first as an ordinary user.
.PP
.SH AUTHORS
Joost Witteveen <joostje@debian.org>, original idea by
Lars Wirzenius <liw@iki.fi>. Now maintained by 
Bill Allombert <ballombe@debian.org>.
.SH THANKS
To Joey Hess, for a lot of good ideas and pre-release testing, and to
Tom Lees for a update-menus in pure C (of which I only used one
function, but that's life).
.PP
Man page by Joey Hess, <joeyh@debian.org>
.SH "SEE ALSO"
.BR menufile (5),
.BR /usr/share/doc/menu/html