code: def add_file_filtering_cli(parser, *, excluded=None):
      parser.add_argument("--start")
      parser.add_argument("--include", action="append")
      parser.add_argument("--exclude", action="append")
  
      excluded = tuple(excluded or ())
  
      def process_args(args, *, argv=None):
          ns = vars(args)
          key = "iter_filenames"
          if key in ns:
              parser.error(f"duplicate arg {key!r}")
  
          _include = tuple(ns.pop("include") or ())
          _exclude = excluded + tuple(ns.pop("exclude") or ())
          kwargs = dict(
              start=ns.pop("start"),
              include=tuple(_parse_files(_include)),
              exclude=tuple(_parse_files(_exclude)),
              # We use the default for "show_header"
          )
  
          def process_filenames(filenames, relroot=None):
              return fsutil.process_filenames(
                  filenames, relroot=relroot, **kwargs
              )
  
          ns[key] = process_filenames
  
      return process_args
  
imports: import argparse
  import contextlib
  import logging
  import os
  import os.path
  import shutil
  import sys
  from .None import fsutil, strutil, iterutil, logging
label_desc: Use image node_id 14 for calling a global function with example usage: add_file_filtering_cli(parser) and returns: process_args, fsutil