add logging of built files

This commit is contained in:
Maximilian Keßler 2022-02-18 10:14:44 +01:00
parent 065734a628
commit 12aa945a9d
2 changed files with 4 additions and 5 deletions

View file

@ -262,6 +262,8 @@ class PyTeXBuilder:
out_dir.mkdir(exist_ok=False, parents=True)
new_config: List[Tuple[RelativePath, FormattingConfig]] = \
source_file.format(self._tmp_dir / source_file.file_hash)
for filename in source_file.output_files:
logger.info(f"[Built] {filename}")
for output_file in source_file.output_files:
# TODO: handle this new config file
# TODO: handle git stuff / meta info stuff
@ -298,12 +300,12 @@ class PyTeXBuilder:
self._load_pytex_files() # 8ms
logger.info(f"Found {len(self._pytex_files)} source files")
self._init_output_files() # 1ms
logger.info(f"Found {len(self._output_files)} potential files to build.")
logger.info(f"Found {len(self._output_files)} potential output files to build.")
self._compute_files_to_build() # 1ms
if len(self._files_to_build) == 0:
logger.info(f"Everything up to date, nothing to build!")
return True
logger.info(f"Needing to build {len(self._files_to_build)} many files.")
logger.info(f"Needing to build {len(self._files_to_build)} many source files.")
self._check_output_directory_integrity() # 1ms
logger.info(f"Starting build")
try:

View file

@ -89,7 +89,4 @@ class DictFormatter(PyTeXFormatter):
output_file.write_text(
''.join(lines)
)
logger.info(
f'Successfully wrote dictionary file {output_file.name}.'
)
return [] # No future configuration needed