src_dir = os.path.join(self.build_path, cli_dir)
if not os.path.exists(src_dir):
cli_init_py = os.path.join(src_dir, '__init__.py')
# Remove old init module to avoid incompatible code and duplication
if os.path.exists(cli_init_py):
gotasks_dir = os.path.join(src_dir, 'gotasks')
gotasks_init_py = os.path.join(gotasks_dir, '__init__.py')
# Remove old init module to avoid incompatible code and duplication
if os.path.exists(gotasks_init_py):
os.remove(gotasks_init_py)
for xml_file in [f for f in os.listdir(src_dir) if f.endswith('.xml')]:
self.announce('Building task from XML: {}'.format(xml_file), level=distutils.log.INFO)