docs: def tee(infile: IO, *files: IO) -> Thread:
      r"""
      Print the file-like object ``infile`` to the file-like object(s) ``files``
      in a separate thread.
      
      Starts and returns that thread.
      
      The type (text, binary) must MATCH across all files.
  
      From 
      https://stackoverflow.com/questions/4984428/python-subprocess-get-childrens-output-to-file-and-terminal
  
      A note on text versus binary IO:
  
      TEXT files include:
      
      - files opened in text mode (``"r"``, ``"rt"``, ``"w"``, ``"wt"``)
      - ``sys.stdin``, ``sys.stdout``
      - ``io.StringIO()``; see
        https://docs.python.org/3/glossary.html#term-text-file
  
      BINARY files include:
      
      - files opened in binary mode (``"rb"``, ``"wb"``, ``"rb+"``...)
      - ``sys.stdin.buffer``, ``sys.stdout.buffer``
      - ``io.BytesIO()``
      - ``gzip.GzipFile()``; see
        https://docs.python.org/3/glossary.html#term-binary-file
  
      .. code-block:: bash
   
          $ python3  # don't get confused and use Python 2 by mistake!
          
      .. code-block:: python
   
          t = open("/tmp/text.txt", "r+t")  # text mode is default
          b = open("/tmp/bin.bin", "r+b")
          
          t.write("hello\n")  # OK
          # b.write("hello\n")  # raises TypeError
          
          # t.write(b"world\n")  # raises TypeError
          b.write(b"world\n")  # OK
          
          t.flush()
          b.flush()
          t.seek(0)
          b.seek(0)
          
          x = t.readline()  # "hello\n"
          y = b.readline()  # b"world\n"
  
      """  # noqa
  
      def fanout(_infile: IO, *_files: IO):
          for line in iter(_infile.readline, ''):
              for f in _files:
                  f.write(line)
          infile.close()
  
      t = Thread(target=fanout, args=(infile,) + files)
      t.daemon = True
      t.start()
      return t