Skip to content

Commit

Permalink
fix strings and docstrings
Browse files Browse the repository at this point in the history
  • Loading branch information
Exirel committed Mar 20, 2019
1 parent 1ca5b3b commit 5101846
Showing 1 changed file with 13 additions and 11 deletions.
24 changes: 13 additions & 11 deletions sopel/cli/config.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# coding=utf-8
"""Sopel Config Command Line Interfaces (CLI): ``sopel-config``"""
"""Sopel Config Command Line Interface (CLI): ``sopel-config``"""
from __future__ import unicode_literals, absolute_import, print_function, division

import argparse
Expand All @@ -22,10 +22,10 @@ def build_parser():
# sopel-config list
list_parser = subparsers.add_parser(
'list',
help='List available configurations from Sopel\'s homedir',
help="List available configurations from Sopel's homedir",
description="""
List available configurations from Sopel's homedir ({homedir}) with the
extension "{ext}".
List available configurations from Sopel's homedir ({homedir})
with the extension "{ext}".
""".format(homedir=config.DEFAULT_HOMEDIR, ext='.cfg'))
list_parser.add_argument(
'-e', '--ext', '--extension',
Expand All @@ -42,15 +42,15 @@ def build_parser():
# sopel-config init
init_parser = subparsers.add_parser(
'init',
help='Initialize sopel configuration file',
description='Initialize sopel configuration file')
help='Initialize Sopel configuration file',
description='Initialize Sopel configuration file')
utils.add_common_arguments(init_parser)

# sopel-config get <section> <key>
get_parser = subparsers.add_parser(
'get',
help='Get a configuration option\'s value',
description='Get a configuration option\'s value',
help="Get a configuration option's value",
description="Get a configuration option's value",
)
get_parser.add_argument('section')
get_parser.add_argument('option')
Expand All @@ -62,7 +62,8 @@ def build_parser():
def handle_list(options):
"""Display a list of configuration available from Sopel's homedir
:param options: argument parser's parsed option
:param options: parsed arguments
:type options: ``argparse.Namespace``
This command displays an unordered list of config names from Sopel's
default homedir, without their extensions::
Expand Down Expand Up @@ -91,12 +92,13 @@ def handle_list(options):
def handle_init(options):
"""Use config wizard to initialize a new configuration file for the bot
:param options: argument parser's parsed options
:param options: parsed arguments
:type options: ``argparse.Namespace``
.. note::
Due to how the config wizard works, the configuration filename's
extension must be ``.cfg``.
extension **must be** ``.cfg``.
"""
config_filename = utils.find_config(
Expand Down

0 comments on commit 5101846

Please sign in to comment.