Puppet Strings command reference
Modify the behavior of Puppet Strings by specifying command actions and options.
puppet strings command
Generates module documentation based on code and code
comments. By default, running puppet
strings
generates HTML documentation for a module into a ./doc/
directory within that module.
To pass options or arguments, such as specifying Markdown or JSON
output, use the generate
action.
Usage:
puppet strings [--generate] [--server]
Action | Description |
---|---|
generate
|
Generates documentation with any specified parameters, including format and output location. |
server
|
Serves documentation locally at http://localhost:8808 for all
modules in the modulepath. For information about the modulepath, see the modulepath documentation. |
puppet strings generate action
Generates documentation with any specified parameters, including format and output location.
Usage:
puppet strings generate [--format <FORMAT>][--out <DESTINATION>] [<ARGUMENTS>]For example:
puppet strings generate --format markdown --out docs/info.md
puppet strings generate manifest1.pp manifest2.pp
Option | Description | Values | Default |
---|---|---|---|
--format
|
Specifies a format for documentation. | Markdown, JSON | If not specified, outputs HTML documentation. |
--out
|
Specifies an output location for documentation. | A valid directory location and filename. | If not specified, outputs to default locations
depending on format:
|
Filenames or directory paths | Outputs documentation for only specified files or directories. | Valid filenames or directory paths | If not specified, outputs documentation for the entire module. |
--debug , -d |
Logs debug information. | None. | If not specified, does not log debug information. |
--help
|
Displays help documentation for the command. | None. | If specified, returns help information. |
--markup
<FORMAT>
|
The markup format to use for documentation |
|
If no --format is specified, outputs HTML. |
--verbose , -v |
Logs verbosely. | None. | If not specified, logs basic information. |
puppet strings server action
Serves documentation locally at http://localhost:8808
for all modules in
the module path.
Usage:
puppet strings server [--markup <FORMAT>][[module_name]...][--modulepath <PATH>]
For example:
puppet strings server --modulepath path/to/modules
puppet strings server concat
Option | Description | Values | Default |
---|---|---|---|
--markup
<FORMAT>
|
The markup format to use for documentation |
|
If no --format is specified, outputs HTML. |
--debug , -d |
Logs debug information. | None. | If not specified, does not log debug information. |
--help
|
Displays help documentation for the command. | None. | If specified, returns help information. |
Module name
|
Generates documentation for the named module only. | A valid module name. | If not specified, generates documentation for all modules in the modulepath. |
--modulepath
|
Puppet option for setting the modulepath. | A valid path. | Defaults to the module path specified in the puppet.conf
file. |
--verbose , -v |
Logs verbosely. | None. | If not specified, logs basic information. |
Available Strings tags
@author
# @author Foo Bar class MyClass; end
@api
# @api private
@example
@param
@!puppet.type.param
@!puppet.type.property
@option
@param
tag to defines what optional parameters the user can
pass in an options hash to the method. For example:
# @param [Hash] opts # List of options # @option opts [String] :option1 # option 1 in the hash # @option opts [Array] :option2 # option 2 in the hash
@raise
# @raise PuppetError this error is raised if x
@return
# An example 4.x function. Puppet::Functions.create_function(:example) do # @param first The first parameter. # @param second The second parameter. # @return [String] If second argument is less than 10, the name of one item. # @return [Array] If second argument is greater than 10, a list of item names. # @example Calling the function. # example('hi', 10) dispatch :example do param 'String', :first param 'Integer', :second end # ... end
@see
@since
@summary