Verified Commit 777bab01 authored by boklm's avatar boklm
Browse files

Bug 33991: Remove unused features

For simplification, we remove some unused features. Those features can
still be reimplemented externally if needed.

For example, the "rbm rpm" command can be replaced with
"rbm build --step rpm" and a definition of an rpm step in rbm.conf.

We remove the following options:
 - version_command
 - rpm
 - rpmbuild
 - srpm
 - rpmspec
 - rpm_rel
 - debian_create
 - deb
 - deb_src
 - use_pbuilder
 - debian_revision

And the following commands:
 - rpmspec
 - rpm
 - srpm
 - deb-src
 - deb
 - pkg
 - publish
parent e0106571
- Remove the version_command, rpm, srpm, rpmbuild, rpmspec, rpm_rel,
debian_create, deb, deb_src, use_pbuilder, and debian_revision options,
as well as the rpmspec, rpm, srpm, deb-src, deb, pkg, and the publish
commands. All of these features can still be implemented externally.
- Add the target_append and target_prepend input_files options
- Add the build_log_append option
......
......@@ -27,14 +27,7 @@ MAN1_ASC += rbm.asc
MAN1_ASC += rbm-usage.asc
MAN1_ASC += rbm-tar.asc
MAN1_ASC += rbm-showconf.asc
MAN1_ASC += rbm-srpm.asc
MAN1_ASC += rbm-rpm.asc
MAN1_ASC += rbm-rpmspec.asc
MAN1_ASC += rbm-fetch.asc
MAN1_ASC += rbm-deb-src.asc
MAN1_ASC += rbm-deb.asc
MAN1_ASC += rbm-pkg.asc
MAN1_ASC += rbm-publish.asc
MAN1_ASC += rbm-build.asc
MAN7_ASC += rbm_tutorial.asc
......
--use-pbuilder::
--no-use-pbuilder::
Whether to use pbuilder when building debian packages
--debsign-keyid=<key id>::
The id of the key to sign debian packages with. Set to 0 for no
signature.
--publish-src-dir::
The directory containing the files that are going to be published.
......@@ -15,12 +15,5 @@ rbm commands :
- link:rbm-tar.html[rbm-tar(1)]
- link:rbm-showconf.html[rbm-showconf(1)]
- link:rbm-build.html[rbm-build(1)]
- link:rbm-srpm.html[rbm-srpm(1)]
- link:rbm-rpm.html[rbm-rpm(1)]
- link:rbm-rpmspec.html[rbm-rpmspec(1)]
- link:rbm-fetch.html[rbm-fetch(1)]
- link:rbm-deb-src.html[rbm-deb-src(1)]
- link:rbm-deb.html[rbm-deb(1)]
- link:rbm-pkg.html[rbm-pkg(1)]
- link:rbm-publish.html[rbm-publish(1)]
......@@ -10,19 +10,6 @@ package creation::
Create binary or source packages from any git or mercurial
revision using a simple command.
packages upload::
Upload the packages that you have built to a repository and
update metadata.
multi-os support::
RPM and debian packages are currently supported. Support for
more packaging systems could easily be added. Using package
templates and the http://www.template-toolkit.org/[Template
Toolkit], you can make different packages for different
distributions using the same files. The syntax of this templating
system is much more clear and powerful than the RPM macros
syntax.
remote builds::
Build your software on a remote server with ssh, or in a local
chroot using a different OS. For instance if you are using
......
debian_revision::
The package revision used in debian packages. By default, when
the option +pkg_rel+ is defined, this is what is used. Otherwise
a revision containing the number of commits since the last git
tag, and the hash of the commit is used.
deb_src::
This is the script that is used to create the debian source
package. By default it will use the debian files listed in the
option +debian_files+ and create the source package with
dpkg-source.
deb::
This is the script that is used to create the debian packages.
By default it will use the debian files listed in the option
+debian_files+ and build the package using debuild or pdebuild
depending on whether the +use_pbuilder+ option is set. The
packages will be signed using the key defined in the option
+debsign_keyid+.
debian_files::
This is an array containing the files to create in the debian
directory. Each item in the array is an hash, with the following
two keys : +name+ is the file name in the debian directory of
the file to create, and +content+ is the content of the file.
The filename and content are processed as template, so for
instance if you want to store the content of a file in a separate
file, you can use the INCLUDE directive.
use_pbuilder::
If set to a true value, pbuilder will be used to build the
debian packages.
debsign_keyid::
This is the gpg key that will be used to sign the debian packages.
Set to 0 if you don't want to sign the packages.
pkg_type::
This is the name of the option that will be used by the +pkg+
command as the script to build the package. This can be +rpm+
or +deb+ for rpm and debian packages. This option is usually
set in distribution specific configuration as it depends on the
distribution being used.
publish::
This is the content of the script that is used to upload the
packages or files to a repository. This script will be executed
from the directory containing the files to publish. This option
has no default value.
rpm_rel::
RPM package release number. The default is to use the option
+pkg_rel+ if defined, otherwise use a release number containing
the number of commits since the last git tag, and the hash of
the commit used.
rpmspec::
This is the content of the rpm spec file, used by the +rpm+ and
+srpm+ commands. The default is to include the template file named
+project.spec+ (with +project+ replaced by the project's name).
rpmbuild::
This is the content of the script to build a rpm or srpm. It is
using the +rpmbuild_action+ option to select the build action
('-bs' to build a source package, or '-ba' to build all packages).
rpm::
This is the script that is used to build an rpm package, in the
+rpm+ command. By default it is using the +rpmbuild+ option with
the '-ba' action.
srpm::
This is the script that is used to build a source rpm package,
in the +srpm+ command. By default it is using the +rpmbuild+
option with the '-bs' action.
rbm-deb-src(1)
==============
NAME
----
rbm-deb-src - Create debian source package
SYNOPSIS
--------
[verse]
'rbm deb-src' <project> [options]
DESCRIPTION
-----------
Create a debian source package for the selected project.
This is equivalent to running 'rbm build --step deb_src <project>'.
CONFIGURATION OPTIONS
---------------------
The following configuration options are related to Debian packages :
include::options_deb.asc[]
See link:rbm_config.html[rbm_config(7)] for all other options.
COMMAND LINE OPTIONS
--------------------
The command line options related to Debian packages are :
include::clioptions_deb.asc[]
See link:rbm_cli.html[rbm_cli(7)] for all other options.
SEE ALSO
--------
link:rbm.html[rbm(1)]
rbm-deb(1)
==========
NAME
----
rbm-deb - Build a debian package
SYNOPSIS
--------
[verse]
'rbm deb' <project> [options]
DESCRIPTION
-----------
Build a debian package.
This is equivalent to running 'rbm build --step deb <project>'.
CONFIGURATION OPTIONS
---------------------
The following configuration options are related to Debian packages :
include::options_deb.asc[]
See link:rbm_config.html[rbm_config(7)] for all other options.
COMMAND LINE OPTIONS
--------------------
The command line options related to Debian packages are :
include::clioptions_deb.asc[]
See link:rbm_cli.html[rbm_cli(7)] for all other options.
SEE ALSO
--------
link:rbm.html[rbm(1)]
rbm-pkg(1)
==========
NAME
----
rbm-pkg - Build a package
SYNOPSIS
--------
[verse]
'rbm pkg' <project> [options]
DESCRIPTION
-----------
Build a package for the selected project. Depending on configuration or
selected distribution, this can be an rpm, deb or other type of package.
CONFIGURATION OPTIONS
---------------------
include::options_pkg.asc[]
See link:rbm_config.html[rbm_config(7)] for all other options.
COMMAND LINE OPTIONS
--------------------
See link:rbm_cli.html[rbm_cli(7)].
SEE ALSO
--------
link:rbm.html[rbm(1)]
rbm-publish(1)
==============
NAME
----
rbm-publish - Publish some packages or files
SYNOPSIS
--------
[verse]
'rbm publish' <project> [--publish-src-dir=<dir>] [options]
DESCRIPTION
-----------
Build a package and publish it. See link:rbm-pkg.html[rbm-pkg(1)]
for details about how the package is built.
If the option '--publish-src-dir' is used, then the package is not built,
and instead the packages or files present in that directory are published.
CONFIGURATION OPTIONS
---------------------
include::options_publish.asc[]
See link:rbm_config.html[rbm_config(7)] for all other options.
COMMAND LINE OPTIONS
--------------------
The command line options related to publish are :
include::clioptions_publish.asc[]
See link:rbm_cli.html[rbm_cli(7)] for all other options.
EXAMPLES
--------
In this example, we want to publish packages for Mageia and Debian. On
Mageia, the repository metadata are generated using 'genhdlist2'. On
Debian the new package is included in the repository using 'reprepro'.
The rbm configuration looks like this :
----
targets:
Mageia:
repo_dir: /path/to/mageia/repo
publish: |
#!/bin/sh
cp -va noarch/*.rpm [% c('repo_dir') %]
genhdlist2 [% c('repo_dir') %]
Debian:
repo_dir: /path/to/debian/repo
publish: |
#!/bin/sh
reprepro -b [% c('repo_dir') %] include \
[% c('lsb_release/codename') %] *.changes
----
If we want to upload the packages on a remote server, before including
them on the repository, this can be done like this :
----
targets:
Debian:
repo_dir: /path/to/debian/repo
publish: |
#!/bin/sh
reprepro -b [% c('repo_dir') %] include \
[% c('lsb_release/codename') %] *.changes
steps:
publish:
ssh_host: publish_server.somedomain
remote_exec: "[% c('remote_ssh') %]"
----
An alternative could be to generate the repository locally, and add an
rsync command at the end of the 'publish' script to upload the repository
to your publication server :
----
targets:
Debian:
local_repo: /path/to/debian/repo
publish: |
#!/bin/sh
reprepro -b [% c('local_repo') %] include \
[% c('lsb_release/codename') %] *.changes
rsync -avH --delete [% c('local_repo') %] publish_server.somedomain:/repo
----
SEE ALSO
--------
link:rbm.html[rbm(1)],
link:rbm-pkg.html[rbm-pkg(1)]
rbm-rpm(1)
==========
NAME
----
rbm-rpm - Build an rpm package
SYNOPSIS
--------
[verse]
'rbm rpm' <project> [options]
DESCRIPTION
-----------
Build an rpm package for the selected project.
This is equivalent to running 'rbm build --step rpm <project>'.
CONFIGURATION OPTIONS
---------------------
The following configuration options are related to rpm packages :
include::options_rpm.asc[]
See link:rbm_config.html[rbm_config(7)] for all other options.
COMMAND LINE OPTIONS
--------------------
See link:rbm_cli.html[rbm_cli(7)].
SEE ALSO
--------
link:rbm.html[rbm(1)]
rbm-rpmspec(1)
==============
NAME
----
rbm-rpmspec - Create a rpm spec file
SYNOPSIS
--------
[verse]
'rbm rpmspec' <project> [options]
DESCRIPTION
-----------
Create an rpm spec file for the selected project.
OPTIONS
-------
See link:rbm_cli.html[rbm_cli(7)].
SEE ALSO
--------
link:rbm.html[rbm(1)]
rbm-srpm(1)
===========
NAME
----
rbm-srpm - Create source rpm package
SYNOPSIS
--------
[verse]
'rbm srpm' <project> [options]
DESCRIPTION
-----------
Create a source rpm package for the select project.
This is equivalent to running 'rbm build --step srpm <project>'.
CONFIGURATION OPTIONS
---------------------
The following configuration options are related to rpm packages :
include::options_rpm.asc[]
See link:rbm_config.html[rbm_config(7)] for all other options.
COMMAND LINE OPTIONS
--------------------
See link:rbm_cli.html[rbm_cli(7)].
SEE ALSO
--------
link:rbm.html[rbm(1)]
......@@ -22,10 +22,10 @@ EXAMPLES
--------
----
$ rbm usage rpm
=> man rbm-rpm
$ rbm deb --help
=> man rbm-deb
$ rbm usage build
=> man rbm-build
$ rbm fetch --help
=> man rbm-fetch
$ rbm --help tar
=> man rbm-tar
----
......
......@@ -71,10 +71,6 @@ The following options can be set on the command line :
include::clioptions_tar.asc[]
include::clioptions_deb.asc[]
include::clioptions_publish.asc[]
SEE ALSO
--------
link:rbm.html[rbm(1)],
......
......@@ -181,14 +181,6 @@ version::
Version number of the software. This is used to create the
tarball, and as the package version number.
version_command::
A command to run in the checked out source tree to determine
the version, if the +version+ option is not set. The command
should print the version on stdout.
pkg_rel::
Package release number.
distribution::
The name of the distribution for which you wish to build a package.
The syntax is +distribution-release+. This value is used by the
......@@ -242,9 +234,9 @@ input_files_paths::
timestamp::
This is the UNIX timestamp, set as modification time on files
created such as the sources tarball and rpm spec file. The
default is to use the commit time of the commit used. If set to
0 it will use the current time.
created such as the sources tarball. The default is to use the
commit time of the commit used. If set to 0 it will use the
current time.
notmpl::
An array containing a list of options that should not be
......@@ -253,29 +245,21 @@ notmpl::
step::
The value of this option is the name of the build script we are
going to be running ('deb' if building a Debian package, 'rpm'
if building an rpm, etc ...). This can be useful in the
+input_files+ definition, if you want to enable an input file
only for some type of package. This option should be used read
only.
going to be running (by default 'build', but you could have an
other one for publishing your build, or for different types of
packaging). This option should be used read only. If you want
to change it, use the --step command line option, or the
+pkg_type+ option.
steps::
The steps definitions. See link:rbm_steps.html[rbm_steps(7)]
for details.
include::options_rpm.asc[]
include::options_deb.asc[]
include::options_pkg.asc[]
build::
This is the content of the build script used by the +build+
command. The default is to include the template file named
+build+.
include::options_publish.asc[]
include::options_misc.asc[]
In addition to the configuration options listed here, you are free to
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment