community.general/lib/ansible/modules/windows/win_file_version.py
Dag Wieers d863027159 Windows: Add missing parameter types and doc fixes (#50232)
* Windows: Add missing parameter types and doc fixes

This PR includes:
- Adding missing parameter types
- Various documentation fixes

* Update lib/ansible/modules/windows/win_copy.py

Co-Authored-By: dagwieers <dag@wieers.com>

* Update lib/ansible/modules/windows/win_credential.py

Co-Authored-By: dagwieers <dag@wieers.com>

* Update lib/ansible/modules/windows/win_domain_computer.py

Co-Authored-By: dagwieers <dag@wieers.com>

* Update lib/ansible/modules/windows/win_domain_user.py

Co-Authored-By: dagwieers <dag@wieers.com>

* Update lib/ansible/modules/windows/win_environment.py

Co-Authored-By: dagwieers <dag@wieers.com>

* Update lib/ansible/modules/windows/win_psexec.py

Co-Authored-By: dagwieers <dag@wieers.com>

* Update lib/ansible/modules/windows/win_uri.py

Co-Authored-By: dagwieers <dag@wieers.com>

* Update lib/ansible/modules/windows/win_wait_for.py

Co-Authored-By: dagwieers <dag@wieers.com>

* Ensure docstrings are raw strings
2019-01-03 10:50:44 -06:00

78 lines
1.6 KiB
Python

#!/usr/bin/python
# -*- coding: utf-8 -*-
# Copyright: (c) 2015, Sam Liu <sam.liu@activenetwork.com>
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
ANSIBLE_METADATA = {'metadata_version': '1.1',
'status': ['preview'],
'supported_by': 'community'}
DOCUMENTATION = r'''
---
module: win_file_version
version_added: "2.1"
short_description: Get DLL or EXE file build version
description:
- Get DLL or EXE file build version.
notes:
- This module will always return no change.
options:
path:
description:
- File to get version.
- Always provide absolute path.
type: path
required: yes
seealso:
- module: win_file
author:
- Sam Liu (@SamLiu79)
'''
EXAMPLES = r'''
- name: Get acm instance version
win_file_version:
path: C:\Windows\System32\cmd.exe
register: exe_file_version
- debug:
msg: '{{ exe_file_version }}'
'''
RETURN = r'''
path:
description: file path
returned: always
type: str
file_version:
description: File version number..
returned: no error
type: str
product_version:
description: The version of the product this file is distributed with.
returned: no error
type: str
file_major_part:
description: the major part of the version number.
returned: no error
type: str
file_minor_part:
description: the minor part of the version number of the file.
returned: no error
type: str
file_build_part:
description: build number of the file.
returned: no error
type: str
file_private_part:
description: file private part number.
returned: no error
type: str
'''