mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-03-26 21:33:12 +00:00
modules s[f-z]*: use f-strings (#10977)
* modules s[f-z]*: use f-strings * add changelog frag
This commit is contained in:
@@ -119,16 +119,16 @@ def main():
|
||||
|
||||
decrypt_cmd = [cmd, "decrypt"]
|
||||
if name:
|
||||
decrypt_cmd.append("--name=" + name)
|
||||
decrypt_cmd.append(f"--name={name}")
|
||||
else:
|
||||
decrypt_cmd.append("--name=")
|
||||
decrypt_cmd.append("--newline=" + ("yes" if newline else "no"))
|
||||
decrypt_cmd.append(f"--newline={'yes' if newline else 'no'}")
|
||||
if timestamp:
|
||||
decrypt_cmd.append("--timestamp=" + timestamp)
|
||||
decrypt_cmd.append(f"--timestamp={timestamp}")
|
||||
if transcode:
|
||||
decrypt_cmd.append("--transcode=" + transcode)
|
||||
decrypt_cmd.append(f"--transcode={transcode}")
|
||||
if user:
|
||||
decrypt_cmd.append("--uid=" + user)
|
||||
decrypt_cmd.append(f"--uid={user}")
|
||||
decrypt_cmd.extend(["-", "-"])
|
||||
|
||||
rc, stdout, stderr = module.run_command(decrypt_cmd, data=secret, binary_data=True)
|
||||
|
||||
Reference in New Issue
Block a user