MCPcopy Create free account
hub / github.com/RT-Thread/rt-thread / Glob

Method Glob

tools/ng/environment.py:225–243  ·  view source on GitHub ↗

Enhanced glob with better error handling. Args: env: SCons Environment pattern: File pattern Returns: List of matching files

(env, pattern: str)

Source from the content-addressed store, hash-verified

223
224 @staticmethod
225 def Glob(env, pattern: str) -> List[str]:
226 """
227 Enhanced glob with better error handling.
228
229 Args:
230 env: SCons Environment
231 pattern: File pattern
232
233 Returns:
234 List of matching files
235 """
236 try:
237 files = Glob(pattern, strings=True)
238 return sorted(files) # Sort for consistent ordering
239 except Exception as e:
240 context = BuildContext.get_current()
241 if context:
242 context.logger.warning(f"Glob pattern '{pattern}' failed: {e}")
243 return []
244
245 @staticmethod
246 def GetBuildOptions(env) -> Dict[str, Any]:

Callers

nothing calls this directly

Calls 1

get_currentMethod · 0.45

Tested by

no test coverage detected