o 0¦iÐ ã @ s d Z ddlZddlZddlZddlZddlZddlZddlZg d¢Zddddœdd„Z ddddœdd „Z d d„ Zdd „ Zdd„ Z dd„ Zdd„ Zdd„ Zdd„ Zdd„ Zdd„ Zdd„ Zdd„ Zd d!„ Ze d"¡Ze d#¡Zd$d%„ Zd&d'„ Zd(d)„ Zd*d+„ Zejeed,dƒB Z dS )-zFilename globbing utility.é N)ÚglobÚiglobÚescapeF©Úroot_dirÚdir_fdÚ recursivec C s t t| |||d�ƒS )ay Return a list of paths matching a pathname pattern. The pattern may contain simple shell-style wildcards a la fnmatch. However, unlike fnmatch, filenames starting with a dot are special cases that are not matched by '*' and '?' patterns. If recursive is true, the pattern '**' will match any files and zero or more directories and subdirectories. r )Úlistr )Úpathnamer r r © r ú+/opt/alt/python310/lib64/python3.10/glob.pyr s r c C s¨ t d| |¡ t d| |||¡ |durt |¡}n| dd… }t| |||dƒ}| r4|rRt| dd… ƒrRzt|ƒ}|rEt |f|¡}W |S W |S t yQ Y |S w |S )aŒ Return an iterator which yields the paths matching a pathname pattern. The pattern may contain simple shell-style wildcards a la fnmatch. However, unlike fnmatch, filenames starting with a dot are special cases that are not matched by '*' and '?' patterns. If recursive is true, the pattern '**' will match any files and zero or more directories and subdirectories. z glob.globzglob.glob/2Nr Fé ) ÚsysÚauditÚosÚfspathÚ_iglobÚ_isrecursiveÚnextÚ itertoolsÚchainÚ StopIteration)r r r r ÚitÚsr r r r s&