Coverage for certbot/display/enhancements.py : 100%

Hot-keys on this page
r m x p toggle line displays
j k next/prev highlighted chunk
0 (zero) top of page
1 (one) first highlighted chunk
"""Certbot Enhancement Display"""
# Define a helper function to avoid verbose code
"""Display the enhancement to the user.
:param str enhancement: One of the :class:`certbot.CONFIG.ENHANCEMENTS` enhancements
:returns: True if feature is desired, False otherwise :rtype: bool
:raises .errors.Error: if the enhancement provided is not supported
""" # Call the appropriate function based on the enhancement
"""Determines whether the user would like to redirect to HTTPS.
:returns: True if redirect is desired, False otherwise :rtype: bool
""" ("No redirect", "Make no further changes to the webserver configuration."), ("Redirect", "Make all requests redirect to secure HTTPS access. " "Choose this for new sites, or if you're confident your site works on HTTPS. " "You can undo this change by editing your web server's configuration."), ]
"Please choose whether or not to redirect HTTP traffic to HTTPS, removing HTTP access.", choices, default=0, cli_flag="--redirect / --no-redirect", force_interactive=True)
"redirect": redirect_by_default } |