code: def __init__(
      self,
      root_dir: PathLike,
      ignore_files: List[str] = None,
      globs: List[str] = None,
  ):
      self.root_dir = Path(root_dir)
      self.ignore_files = (
          ignore_files
          if ignore_files is not None
          else [".gitignore", ".git/info/exclude", ".dstackignore"]
      )
      self.ignore_globs: Dict[str, List[str]] = {".": globs or []}
      self.load_recursive()
  
file_path: dstack/src/dstack/_internal/utils/ignore.py
imports: import fnmatch
  from itertools import zip_longest
  from pathlib import Path
  from typing import Dict, List, Optional
  from dstack._internal.utils.path import PathLike
label_desc: Use image node_id 1 to create a new GitIgnore object  with example: obj = GitIgnore(root_dir, ignore_files, globs)