"""Filetype information.
"""fromtypingimportTuplefrompip._internal.utils.miscimportsplitextWHEEL_EXTENSION=".whl"BZ2_EXTENSIONS:Tuple[str, ...]=(".tar.bz2",".tbz")XZ_EXTENSIONS:Tuple[str, ...]=(".tar.xz",".txz",".tlz",".tar.lz",".tar.lzma",)ZIP_EXTENSIONS:Tuple[str, ...]=(".zip",WHEEL_EXTENSION)TAR_EXTENSIONS:Tuple[str, ...]=(".tar.gz",".tgz",".tar")ARCHIVE_EXTENSIONS=ZIP_EXTENSIONS+BZ2_EXTENSIONS+TAR_EXTENSIONS+XZ_EXTENSIONSdefis_archive_file(name:str)->bool:"""Return True if `name` is a considered as an archive file."""ext=splitext(name)[1].lower()ifextinARCHIVE_EXTENSIONS:returnTruereturnFalse