Bug 737823 - [PATCH] workflow-xslt: Implement support for boolean arguments
Summary: [PATCH] workflow-xslt: Implement support for boolean arguments
Alias: None
Product: Beaker
Classification: Retired
Component: command line
Version: 0.7
Hardware: Unspecified
OS: Unspecified
unspecified vote
Target Milestone: ---
Assignee: Bill Peck
QA Contact:
Depends On:
TreeView+ depends on / blocked
Reported: 2011-09-13 08:01 UTC by David Sommerseth
Modified: 2019-05-22 13:40 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2011-10-20 06:19:10 UTC

Attachments (Terms of Use)

Description David Sommerseth 2011-09-13 08:01:16 UTC
New feature for workflow-xslt:

workflow-xslt: Implement support for boolean arguments

This patch implements support for defining boolean argument types
in the job XML configuration. When this is used, workflow-xslt will
setup an argument which takes no options. When this option is present
the resulting XML file will use the value 'true' in the corresponding
XML tag/attribute.

Signed-off-by: David Sommerseth <davids@redhat.com>


Comment 2 Raymond Mancy 2011-09-20 03:47:44 UTC
I tried to run and verify this change on my local box, and I think it works as expected,

I used the example-job.xml from the man page and added: 

  <arg section="recipe" type="bool">
    <tag type="attribute" attrname="foo">name</tag>
    <description>foo identifier</description

And then ran the following:

  bkr workflow-xslt --dry-run --job-xml example_job.xml --save-internal-xml  example.xml -i 99 -n "Example" -g "Group1" --phone-numbers 123,456,789 --foo

The results it spat out was:

      <name foo="true" group="Group1" version="99">Example</name>

This seems fine to me.

Comment 3 David Sommerseth 2011-09-20 09:23:30 UTC
ACK.  This is exactly how this feature is designed to work.

Note You need to log in before you can comment on or make changes to this bug.