Skip to content

Commit c14a5b9

Browse files
committed
Add docstrings
1 parent 39a5caa commit c14a5b9

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

tools/toolchains/__init__.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -507,12 +507,20 @@ def need_update(self, target, dependencies):
507507
return False
508508

509509
def is_ignored(self, file_path):
510+
"""Check if file path is ignored by any .mbedignore thus far"""
510511
for pattern in self.ignore_patterns:
511512
if fnmatch.fnmatch(file_path, pattern):
512513
return True
513514
return False
514515

515516
def add_ignore_patterns(self, root, base_path, patterns):
517+
"""Add a series of patterns to the ignored paths
518+
519+
Positional arguments:
520+
root - the directory containing the ignore file
521+
base_path - the location that the scan started from
522+
patterns - the list of patterns we will ignore in the future
523+
"""
516524
real_base = relpath(root, base_path)
517525
if real_base == ".":
518526
self.ignore_patterns.extend(patterns)

0 commit comments

Comments
 (0)