Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
ansible
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenEdx
ansible
Commits
2d33cd1b
Commit
2d33cd1b
authored
Apr 08, 2014
by
James Tanner
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixes #6894 add missing file and remove debug line
parent
68cd7258
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
58 additions
and
1 deletions
+58
-1
lib/ansible/utils/module_docs.py
+0
-1
lib/ansible/utils/module_docs_fragments/files.py
+58
-0
No files found.
lib/ansible/utils/module_docs.py
View file @
2d33cd1b
...
@@ -82,7 +82,6 @@ def get_docstring(filename, verbose=False):
...
@@ -82,7 +82,6 @@ def get_docstring(filename, verbose=False):
raise
Exception
(
"missing options in fragment, possibly misformatted?"
)
raise
Exception
(
"missing options in fragment, possibly misformatted?"
)
for
key
,
value
in
fragment
.
items
():
for
key
,
value
in
fragment
.
items
():
open
(
"/tmp/awx.log"
,
"a"
)
.
write
(
"key:
%
s value:
%
s
\n
"
%
(
key
,
value
))
if
not
doc
.
has_key
(
key
):
if
not
doc
.
has_key
(
key
):
doc
[
key
]
=
value
doc
[
key
]
=
value
else
:
else
:
...
...
lib/ansible/utils/module_docs_fragments/files.py
0 → 100644
View file @
2d33cd1b
# (c) 2014, Matt Martz <matt@sivel.net>
#
# This file is part of Ansible
#
# Ansible is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# Ansible is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Ansible. If not, see <http://www.gnu.org/licenses/>.
class
ModuleDocFragment
(
object
):
# Standard files documentation fragment
DOCUMENTATION
=
"""
options:
path:
description:
- 'path to the file being managed. Aliases: I(dest), I(name)'
required: true
default: []
aliases: ['dest', 'name']
state:
description:
- If C(directory), all immediate subdirectories will be created if they
do not exist. If C(file), the file will NOT be created if it does not
exist, see the M(copy) or M(template) module if you want that behavior.
If C(link), the symbolic link will be created or changed. Use C(hard)
for hardlinks. If C(absent), directories will be recursively deleted,
and files or symlinks will be unlinked. If C(touch) (new in 1.4), an empty file will
be created if the c(path) does not exist, while an existing file or
directory will receive updated file access and modification times (similar
to the way `touch` works from the command line).
required: false
default: file
choices: [ file, link, directory, hard, touch, absent ]
src:
required: false
default: null
choices: []
description:
- path of the file to link to (applies only to C(state= link or hard)). Will accept absolute,
relative and nonexisting (with C(force)) paths. Relative paths are not expanded.
recurse:
required: false
default: "no"
choices: [ "yes", "no" ]
version_added: "1.1"
description:
- recursively set the specified file attributes (applies only to state=directory)
"""
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment