def _import(subs, shared):
    """Configure the `doorstop import` subparser."""
    info = 'import an existing document or item'
    sub = subs.add_parser('import', description=info.capitalize() + '.',
        help=info, **shared)
    sub.add_argument('path', nargs='?', help=
        'path to previously exported document file')
    sub.add_argument('prefix', nargs='?', help='prefix of document for import')
    group = sub.add_mutually_exclusive_group()
    group.add_argument('-d', '--document', nargs=2, metavar='ARG', help=
        'import an existing document by: PREFIX PATH')
    group.add_argument('-i', '--item', nargs=2, metavar='ARG', help=
        'import an existing item by: PREFIX UID')
    sub.add_argument('-p', '--parent', metavar='PREFIX', help=
        'parent document prefix for imported document')
    sub.add_argument('-a', '--attrs', metavar='DICT', help=
        'dictionary of item attributes to import')
    sub.add_argument('-m', '--map', metavar='DICT', help=
        'dictionary of custom item attribute names')
