Skip to content

Commit 5c47258

Browse files
committed
Replace print statements with logging.warning
1 parent 3fbdeab commit 5c47258

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

mkdocs_git_authors_plugin/util.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
from git import Repo
2+
import logging
23
from pathlib import Path
34

45
class Util:
@@ -28,12 +29,12 @@ def get_authors(self, path):
2829
try:
2930
blame = self.repo.blame('HEAD',path)
3031
except:
31-
print("WARNING - %s has no commits" % path)
32+
logging.warning("%s has no commits" % path)
3233
self._authors[path] = False
3334
return []
3435

3536
if len(Path(path).read_text()) == 0:
36-
print("WARNING - %s has no lines" % path)
37+
logging.warning("%s has no lines" % path)
3738
self._authors[path] = False
3839
return []
3940

0 commit comments

Comments
 (0)