code: def print_named_configs(ingredient):  # noqa: D202
      """Returns a command that prints named configs recursively.
  
      The command function prints the available named configs for the
      ingredient and all sub-ingredients and exits.
  
      Example
      -------
      The output is highlighted:
          white: config names
          grey:  doc
      """
  
      def print_named_configs():
          """Print the available named configs and exit."""
          named_configs = OrderedDict(ingredient.gather_named_configs())
          print(_format_named_configs(named_configs, 2))
  
      return print_named_configs
  
file_path: sacred/sacred/commands.py
imports: import copy
  import pprint
  import pydoc
  import re
  from collections import namedtuple, OrderedDict
  from colorama import Fore, Style
  from sacred.config import save_config_file
  from sacred.serializer import flatten
  from sacred.utils import PATHCHANGE, iterate_flattened_separately
label_desc: Use image node_id 4 for calling a global function with example usage: print_named_configs(ingredient) and returns: print_named_configs