class documentation
class SpecFile(object):
Class for parsing/modifying spec files
| Method | __init__ |
Undocumented |
| Method | get |
Get the %changelog section |
| Method | macro |
Expand the rpm macros (that gbp knows of) in the given text. |
| Method | patchseries |
Return non-ignored patches of the RPM as a gbp patchseries |
| Method | set |
Update or create the %changelog section |
| Method | set |
Update a tag in spec file content |
| Method | sources |
Get all source tags as a dict |
| Method | update |
Update spec with new patch tags and patch macros |
| Method | write |
Write, possibly updated, spec to disk |
| Class Variable | directive |
Undocumented |
| Class Variable | gbptag |
Undocumented |
| Class Variable | section |
Undocumented |
| Class Variable | tag |
Undocumented |
| Instance Variable | epoch |
Undocumented |
| Instance Variable | name |
Undocumented |
| Instance Variable | orig |
Undocumented |
| Instance Variable | packager |
Undocumented |
| Instance Variable | release |
Undocumented |
| Instance Variable | upstreamversion |
Undocumented |
| Property | ignorepatches |
Get numbers of ignored patches as a sorted list |
| Property | specpath |
Get the dir/filename |
| Property | version |
Get the (downstream) version |
| Static Method | _patch |
Parse arguments of the '%patch' macro |
| Static Method | _setup |
Parse arguments of the '%setup' macro |
| Method | _delete |
Delete a special macro line in spec file content |
| Method | _delete |
Delete a tag |
| Method | _guess |
Try to guess the name of the primary upstream/source archive. Returns a dict with all the relevant information. |
| Method | _guess |
Guess prefix for the orig file |
| Method | _macro |
Undocumented |
| Method | _parse |
Go through spec file content line-by-line and (re-)parse info from it |
| Method | _parse |
Parse special directive/scriptlet/macro lines |
| Method | _parse |
Parse a filtered spec file in rpm-python |
| Method | _parse |
Parse special git-buildpackage tags |
| Method | _parse |
Parse tag line |
| Method | _patches |
Get all patch tags as a dict |
| Method | _set |
Update/create a complete section in spec file. |
| Method | _set |
Update a special macro line in spec file content |
| Method | _set |
Set a tag value |
| Method | _sources |
Get all source tags as a dict |
| Instance Variable | _content |
Undocumented |
| Instance Variable | _filtertags |
Undocumented |
| Instance Variable | _gbp |
Undocumented |
| Instance Variable | _listtags |
Undocumented |
| Instance Variable | _special |
Undocumented |
| Instance Variable | _specinfo |
Undocumented |
| Instance Variable | _tags |
Undocumented |
Expand the rpm macros (that gbp knows of) in the given text.
| Parameters | |
| text:str | text to check for macros |
| Returns | |
| str | text with macros expanded |
Try to guess the name of the primary upstream/source archive. Returns a dict with all the relevant information.