Actions
Feature #21633
closedAllow modification of additional help texts
Difficulty:
Triaged:
No
Pull request:
Team Backlog:
Description
Hammer allows to append additional texts to standard help generated for commands. It's currently not possible to modify the help text and pugins can't add paragraphs or lists to existing sections in help.
TextBuilder in help should provide interface for looking up help items (sections, lists, texts) and modifying their contents, e.g.:
# Find existing section ':provider_options' and add section 'Libvirt' base.extend_help do |h| h.find_section(:provider_options).section(_('Libvirt')) do |h| h.list([ ['cpus', _('Number of CPUs')], ['memory', _('String, amount of memory, value in bytes')], ['start', _('Boolean (expressed as 0 or 1), whether to start the machine or not')] ]) end end
Updated by Tomáš Strachota almost 7 years ago
- Related to Feature #21635: Extensible commands in hammer added
Updated by Oleh Fedorenko over 6 years ago
- Status changed from New to Assigned
- Assignee set to Oleh Fedorenko
Updated by The Foreman Bot over 6 years ago
- Status changed from Assigned to Ready For Testing
- Pull request https://github.com/theforeman/hammer-cli/pull/277 added
Updated by Oleh Fedorenko about 6 years ago
- Status changed from Ready For Testing to Closed
Applied in changeset 99cf9e5bc568e7a95b153dd370b01fa6829c6c1f.
Actions