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

Function HandleExcludingOption

tools/targets/eclipse.py:467–493  ·  view source on GitHub ↗
(entry, sourceEntries, excluding)

Source from the content-addressed store, hash-verified

465
466
467def HandleExcludingOption(entry, sourceEntries, excluding):
468 old_excluding = []
469 if entry != None:
470 exclud = entry.get('excluding')
471 if exclud != None:
472 old_excluding = entry.get('excluding').split('|')
473 sourceEntries.remove(entry)
474
475 value = ''
476 for item in old_excluding:
477 if item.startswith('//'):
478 old_excluding.remove(item)
479 else:
480 if value == '':
481 value = item
482 else:
483 value += '|' + item
484
485 for item in excluding:
486 # add special excluding path prefix for RT-Thread
487 item = '//' + item
488 if value == '':
489 value = item
490 else:
491 value += '|' + item
492
493 SubElement(sourceEntries, 'entry', {'excluding': value, 'flags': 'VALUE_WORKSPACE_PATH|RESOLVED', 'kind':'sourcePath', 'name':""})
494
495
496def UpdateCproject(env, project, excluding, reset, prj_name):

Callers 1

UpdateCprojectFunction · 0.85

Calls 1

getMethod · 0.45

Tested by

no test coverage detected