another sandbox, then inspected.
The `build.py` helper script can build a set of SRPMs/RPMs based on provided
-version arguments or all defined builds.
+version arguments.
```
[vagrant@localhost ~]$ /vagrant/build.py -h
usage: build.py [-h] [-v [major minor patch rpm [major minor patch rpm ...]]]
- [-a]
optional arguments:
-h, --help show this help message and exit
-v [major minor patch rpm [major minor patch rpm ...]], --version [major minor patch rpm [major minor patch rpm ...]]
RPM version(s) to build
- -a, --all Build all RPMs
```
The `-v`/`--version` flag accepts a version number. Any build that matches
the match unique. For example, `build.py -v 2 4 0 1` could only match one
definition (Helium SR4, 2.4.0-1).
-To build all RPMs defined in `build_vars.yaml`, use `build.py -a`.
-
The `build.py` script uses the `cache/cache.py` script to handled downloading
and caching the artifacts required for the requested builds. Artifacts are
cached in the `packaging/rpm/cache/` directory.
parser.add_argument("-v", "--version", action="append",
metavar="major minor patch rpm", nargs="*",
help="RPM version(s) to build")
- parser.add_argument("-a", "--all", action="store_true",
- help="Build all RPMs")
# Print help if no arguments are given
if len(sys.argv) == 1:
# Build list of RPM builds to perform
builds = []
- if args.all:
- builds = build_vars["builds"]
- else:
+ if args.version:
# Build a list of requested versions as dicts of version components
versions = []
version_keys = ["version_major", "version_minor", "version_patch",