summaryrefslogtreecommitdiff
path: root/windows/win_regedit.py
diff options
context:
space:
mode:
author= <jhawkesworth@users.noreply.github.com>2016-04-26 18:26:50 +0100
committer= <jhawkesworth@users.noreply.github.com>2016-04-26 18:26:50 +0100
commitd198d025de7aaecb0ae63335d31947da017a1b00 (patch)
treee05ba58d6f2009999b0f0567cc0ef6288b780d79 /windows/win_regedit.py
parentde22b721db288e1c3894b3d763442813e8bcc4f2 (diff)
downloadansible-modules-extras-d198d025de7aaecb0ae63335d31947da017a1b00.tar.gz
Fix for https://github.com/ansible/ansible-modules-extras/issues/2090
Diffstat (limited to 'windows/win_regedit.py')
-rw-r--r--windows/win_regedit.py15
1 files changed, 13 insertions, 2 deletions
diff --git a/windows/win_regedit.py b/windows/win_regedit.py
index 47dc0a6c..8845f8ce 100644
--- a/windows/win_regedit.py
+++ b/windows/win_regedit.py
@@ -43,7 +43,7 @@ options:
aliases: []
data:
description:
- - Registry Value Data. Binary data should be expressed as comma separated hex values. An easy way to generate this is to run C(regedit.exe) and use the I(Export) option to save the registry values to a file. In the exported file binary values will look like C(hex:be,ef,be,ef). The C(hex:) prefix is optional.
+ - Registry Value Data. Binary data should be expressed a yaml byte array or as comma separated hex values. An easy way to generate this is to run C(regedit.exe) and use the I(Export) option to save the registry values to a file. In the exported file binary values will look like C(hex:be,ef,be,ef). The C(hex:) prefix is optional.
required: false
default: null
aliases: []
@@ -96,13 +96,24 @@ EXAMPLES = '''
# Creates Registry Key called MyCompany,
# a value within MyCompany Key called "hello", and
- # binary data for the value "hello" as type "binary".
+ # binary data for the value "hello" as type "binary"
+ # data expressed as comma separated list
win_regedit:
key: HKCU:\Software\MyCompany
value: hello
data: hex:be,ef,be,ef,be,ef,be,ef,be,ef
datatype: binary
+ # Creates Registry Key called MyCompany,
+ # a value within MyCompany Key called "hello", and
+ # binary data for the value "hello" as type "binary"
+ # data expressed as yaml array of bytes
+ win_regedit:
+ key: HKCU:\Software\MyCompany
+ value: hello
+ data: [0xbe,0xef,0xbe,0xef,0xbe,0xef,0xbe,0xef,0xbe,0xef]
+ datatype: binary
+
# Delete Registry Key MyCompany
# NOTE: Not specifying a value will delete the root key which means
# all values will be deleted