New Package: obmenu-generator perl script to auto generate openbox
menu (expecially applications menu)
This commit is contained in:
parent
12305d354f
commit
47c0bafc27
3 changed files with 107 additions and 0 deletions
4
srcpkgs/obmenu-generator/INSTALL.msg
Normal file
4
srcpkgs/obmenu-generator/INSTALL.msg
Normal file
|
@ -0,0 +1,4 @@
|
|||
|
||||
See README.void in /usr/share/doc/obmenu-generator
|
||||
|
||||
Void Mantainers
|
81
srcpkgs/obmenu-generator/files/README.void
Normal file
81
srcpkgs/obmenu-generator/files/README.void
Normal file
|
@ -0,0 +1,81 @@
|
|||
README.void
|
||||
|
||||
To properly use obmenu-generator in void linux you have to tweak
|
||||
two files:
|
||||
|
||||
A config file, auto generated by obmenu-generator:
|
||||
|
||||
~/.config/obmenu-generator/config.pl
|
||||
|
||||
|
||||
The Schema file that you have to copy from:
|
||||
|
||||
/etc/xdg/obmenu-generator/schema.pl
|
||||
|
||||
in:
|
||||
|
||||
~/.config/obmenu-generator/schema.pl
|
||||
|
||||
|
||||
Both files are well documentend into the code.
|
||||
|
||||
Read also the comments in the code of
|
||||
|
||||
/usr/bin/obmenu-generator
|
||||
|
||||
(it's a perl script) for more advanced use.
|
||||
|
||||
Modify ~/.config/obmenu-generator/schema.pl according to your
|
||||
needs to adapt the categories names to your language after theese lines
|
||||
|
||||
{sep => "desidered name of the submenu"}, (see below for the default).
|
||||
|
||||
<begin code extract>
|
||||
{sep => 'Applications'},
|
||||
|
||||
# NAME LABEL ICON
|
||||
{cat => ['utility', 'Accessories', 'applications-utilities']},
|
||||
{cat => ['development', 'Development', 'applications-development']},
|
||||
<end code extract>
|
||||
|
||||
The LABEL column is the place where you localize the names.
|
||||
|
||||
If you use it as a submenu it's better to commentig out the lines from:
|
||||
|
||||
## Custom advanced settings
|
||||
|
||||
till:
|
||||
|
||||
{exit => ['Exit', 'exit']},
|
||||
|
||||
prior the closing ]
|
||||
|
||||
The config.pl is created by obmenu-generator but you may want to customize
|
||||
the language of the auto generated names, for that you have to modify a line
|
||||
near the end, modifying the "name_keys" key to read as follow (substituing
|
||||
the [it] to your preferred language code).
|
||||
|
||||
"name_keys" => ['Name[it]', 'GenericName[it]', 'Name'],
|
||||
|
||||
Accordig to the comment in the script the modifications you have done
|
||||
do in the config.pl may be overridden by the program itself, so be
|
||||
prepared to rewrite every line you modify in the config.pl file from time to
|
||||
time (it is better to copy the config.pl file say to config.pl.mine).
|
||||
|
||||
After you have done the desired modification, insert this line in your
|
||||
menu.xml where you want the menu will be:
|
||||
|
||||
<menu id="obmenu-generator" label="<Your Menu Name>" execute="/usr/bin/obmenu-generator -i"/>
|
||||
|
||||
Then do openbox -reconfigure (or use the menu entry that usually come with
|
||||
openbox) and enjoy your new application menu.
|
||||
|
||||
The script is very powerful and has many other use even to autogenerate a
|
||||
menu.xml, read the documentation and better the comments that are more up to
|
||||
date at:
|
||||
|
||||
http://trizenx.blogspot.ro/2012/02/obmenu-generator.html
|
||||
|
||||
Happy obmenu-generator!
|
||||
|
||||
The Void Mantainers
|
22
srcpkgs/obmenu-generator/template
Normal file
22
srcpkgs/obmenu-generator/template
Normal file
|
@ -0,0 +1,22 @@
|
|||
# Template file for 'obmenu-generator'
|
||||
pkgname=obmenu-generator
|
||||
version=0.60
|
||||
revision=1
|
||||
maintainer="Carlo Dormeletti <carlo(dot)dormeletti(at)alice(dot)it>"
|
||||
homepage="http://trizenx.blogspot.ro/2012/02/obmenu-generator.html"
|
||||
license="GPL-3"
|
||||
short_desc="Perl Script to generate Openbox menu"
|
||||
depends="perl>=5.20 perl-Linux-DesktopFiles"
|
||||
distfiles="https://github.com/trizen/${pkgname}/archive/${version}.tar.gz"
|
||||
checksum="437cca97b3225b0dc5dc642c797ad30b7f1fe6024b9c6272fb6c6ed6c84c9643"
|
||||
|
||||
do_install() {
|
||||
vbin obmenu-generator
|
||||
vmkdir /etc/xdg/${pkgname}
|
||||
vinstall schema.pl 644 /etc/xdg/${pkgname}
|
||||
vdoc README.md
|
||||
vdoc ${FILESDIR}/README.void
|
||||
vdoc schema.pl
|
||||
}
|
||||
|
||||
# vim: set ts=4 sw=4 sts=4 et:
|
Loading…
Reference in a new issue