diff --git a/plugins/modules/files/xml.py b/plugins/modules/files/xml.py index f93c8e4dc4..e7c6ca3f1e 100644 --- a/plugins/modules/files/xml.py +++ b/plugins/modules/files/xml.py @@ -301,6 +301,23 @@ EXAMPLES = r''' - floor: Grog storage - construction_date: "1990" # Only strings are valid - building: Grog factory + +# Consider this XML for following example - +# +# +# +# part to remove +# +# +# part to keep +# +# + +- name: Delete element node based upon attribute + community.general.xml: + path: bar.xml + xpath: /config/element[@name='test1'] + state: absent ''' RETURN = r'''