mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-25 14:20:22 -07:00
Update docs with references to man pages (#8983)
* update docs with references to man pages * reformat module docs * gconftool2/_info: docs adjustments
This commit is contained in:
parent
29a2df8e6b
commit
5b4f41748d
10 changed files with 461 additions and 434 deletions
|
@ -7,16 +7,17 @@
|
|||
from __future__ import absolute_import, division, print_function
|
||||
__metaclass__ = type
|
||||
|
||||
DOCUMENTATION = '''
|
||||
DOCUMENTATION = """
|
||||
---
|
||||
module: gio_mime
|
||||
author:
|
||||
- "Alexei Znamensky (@russoz)"
|
||||
- "Alexei Znamensky (@russoz)"
|
||||
short_description: Set default handler for MIME type, for applications using Gnome GIO
|
||||
version_added: 7.5.0
|
||||
description:
|
||||
- This module allows configuring the default handler for a specific MIME type, to be used by applications built with th Gnome GIO API.
|
||||
- This module allows configuring the default handler for a specific MIME type, to be used by applications built with th Gnome GIO API.
|
||||
extends_documentation_fragment:
|
||||
- community.general.attributes
|
||||
- community.general.attributes
|
||||
attributes:
|
||||
check_mode:
|
||||
support: full
|
||||
|
@ -25,24 +26,28 @@ attributes:
|
|||
options:
|
||||
mime_type:
|
||||
description:
|
||||
- MIME type for which a default handler will be set.
|
||||
- MIME type for which a default handler will be set.
|
||||
type: str
|
||||
required: true
|
||||
handler:
|
||||
description:
|
||||
- Default handler will be set for the MIME type.
|
||||
- Default handler will be set for the MIME type.
|
||||
type: str
|
||||
required: true
|
||||
notes:
|
||||
- This module is a thin wrapper around the C(gio mime) command (and subcommand).
|
||||
- See man gio(1) for more details.
|
||||
- This module is a thin wrapper around the C(gio mime) command (and subcommand).
|
||||
- See man gio(1) for more details.
|
||||
seealso:
|
||||
- name: GIO Documentation
|
||||
description: Reference documentation for the GIO API..
|
||||
link: https://docs.gtk.org/gio/
|
||||
'''
|
||||
- name: C(gio) command manual page
|
||||
description: Manual page for the command.
|
||||
link: https://man.archlinux.org/man/gio.1
|
||||
- name: GIO Documentation
|
||||
description: Reference documentation for the GIO API..
|
||||
link: https://docs.gtk.org/gio/
|
||||
"""
|
||||
|
||||
EXAMPLES = """
|
||||
---
|
||||
- name: Set chrome as the default handler for https
|
||||
community.general.gio_mime:
|
||||
mime_type: x-scheme-handler/https
|
||||
|
@ -50,26 +55,27 @@ EXAMPLES = """
|
|||
register: result
|
||||
"""
|
||||
|
||||
RETURN = '''
|
||||
handler:
|
||||
description:
|
||||
- The handler set as default.
|
||||
returned: success
|
||||
type: str
|
||||
sample: google-chrome.desktop
|
||||
stdout:
|
||||
description:
|
||||
- The output of the C(gio) command.
|
||||
returned: success
|
||||
type: str
|
||||
sample: Set google-chrome.desktop as the default for x-scheme-handler/https
|
||||
stderr:
|
||||
description:
|
||||
- The error output of the C(gio) command.
|
||||
returned: failure
|
||||
type: str
|
||||
sample: 'gio: Failed to load info for handler "never-existed.desktop"'
|
||||
'''
|
||||
RETURN = """
|
||||
---
|
||||
handler:
|
||||
description:
|
||||
- The handler set as default.
|
||||
returned: success
|
||||
type: str
|
||||
sample: google-chrome.desktop
|
||||
stdout:
|
||||
description:
|
||||
- The output of the C(gio) command.
|
||||
returned: success
|
||||
type: str
|
||||
sample: Set google-chrome.desktop as the default for x-scheme-handler/https
|
||||
stderr:
|
||||
description:
|
||||
- The error output of the C(gio) command.
|
||||
returned: failure
|
||||
type: str
|
||||
sample: 'gio: Failed to load info for handler "never-existed.desktop"'
|
||||
"""
|
||||
|
||||
from ansible_collections.community.general.plugins.module_utils.module_helper import ModuleHelper
|
||||
from ansible_collections.community.general.plugins.module_utils.gio_mime import gio_mime_runner, gio_mime_get
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue