code: def list_all_src_files(
      file_regex, ignore_regex, srcdirs, dstdir, inplace
  ):
      allFiles = []
      for srcdir in srcdirs:
          for root, dirs, files in os.walk(srcdir):
              for f in files:
                  if re.search(file_regex, f):
                      src = os.path.join(root, f)
                      if re.search(ignore_regex, src):
                          continue
                      if inplace:
                          _dir = root
                      else:
                          _dir = os.path.join(dstdir, root)
                      dst = os.path.join(_dir, f)
                      allFiles.append((src, dst))
      return allFiles
  
file_path: cusignal/cpp/scripts/run-clang-format.py
imports: from __future__ import print_function
  import argparse
  import os
  import re
  import subprocess
  import sys
  import tempfile
label_desc: Use image node_id 2 for calling a global function with example usage: list_all_src_files(file_regex, ignore_regex, srcdirs, dstdir, inplace) and returns: allFiles