mirror of
https://github.com/Garmelon/PFERD.git
synced 2023-12-21 10:23:01 +01:00
Overhaul colours
"Crawled" and "Downloaded" are now printed less bright than "Crawling" and "Downloading" as they're not as important. Explain topics are printed in yellow to stand out a bit more from the cyan action messages.
This commit is contained in:
parent
9cce78669f
commit
ce1dbda5b4
@ -99,7 +99,7 @@ class CrawlToken(ReusableAsyncContextManager[ProgressBar]):
|
|||||||
|
|
||||||
async def _on_aenter(self) -> ProgressBar:
|
async def _on_aenter(self) -> ProgressBar:
|
||||||
bar_desc = f"[bold bright_cyan]Crawling[/] {escape(fmt_path(self._path))}"
|
bar_desc = f"[bold bright_cyan]Crawling[/] {escape(fmt_path(self._path))}"
|
||||||
after_desc = f"[bold bright_cyan]Crawled[/] {escape(fmt_path(self._path))}"
|
after_desc = f"[bold cyan]Crawled[/] {escape(fmt_path(self._path))}"
|
||||||
|
|
||||||
self._stack.callback(lambda: log.action(after_desc))
|
self._stack.callback(lambda: log.action(after_desc))
|
||||||
await self._stack.enter_async_context(self._limiter.limit_crawl())
|
await self._stack.enter_async_context(self._limiter.limit_crawl())
|
||||||
|
@ -181,7 +181,7 @@ directly or as a GitHub issue: https://github.com/Garmelon/PFERD/issues/new
|
|||||||
"""
|
"""
|
||||||
|
|
||||||
if self.output_explain:
|
if self.output_explain:
|
||||||
self.print(f"[cyan]{escape(text)}")
|
self.print(f"[yellow]{escape(text)}")
|
||||||
|
|
||||||
def explain(self, text: str) -> None:
|
def explain(self, text: str) -> None:
|
||||||
"""
|
"""
|
||||||
|
@ -399,7 +399,7 @@ class OutputDirectory:
|
|||||||
|
|
||||||
async def _after_download(self, info: DownloadInfo) -> None:
|
async def _after_download(self, info: DownloadInfo) -> None:
|
||||||
with self._ensure_deleted(info.tmp_path):
|
with self._ensure_deleted(info.tmp_path):
|
||||||
log.action(f"[bold bright_cyan]Downloaded[/] {fmt_path(info.remote_path)}")
|
log.action(f"[bold cyan]Downloaded[/] {fmt_path(info.remote_path)}")
|
||||||
log.explain_topic(f"Processing downloaded file for {fmt_path(info.path)}")
|
log.explain_topic(f"Processing downloaded file for {fmt_path(info.path)}")
|
||||||
|
|
||||||
changed = False
|
changed = False
|
||||||
|
Loading…
Reference in New Issue
Block a user