summaryrefslogtreecommitdiffstats
path: root/g2h/page_factory.py
diff options
context:
space:
mode:
authorChristoph Schlosser <christoph@linux.com>2025-08-24 17:58:29 +0200
committerChristoph Schlosser <christoph@linux.com>2025-08-24 18:17:07 +0200
commitd8d67f6ba38388aecbf66d791432d5cd3aa8db6e (patch)
tree1cf1c79460d80addcc3e7dcf43b6ae2ad42cacca /g2h/page_factory.py
parentb921db2d6504cee332cf54346dd1c81d034d3acf (diff)
downloadgit2hugo-d8d67f6ba38388aecbf66d791432d5cd3aa8db6e.tar.gz
g2h: Add --content-subdir arg
Diffstat (limited to 'g2h/page_factory.py')
-rw-r--r--g2h/page_factory.py9
1 files changed, 5 insertions, 4 deletions
diff --git a/g2h/page_factory.py b/g2h/page_factory.py
index f946e7a..43a48ae 100644
--- a/g2h/page_factory.py
+++ b/g2h/page_factory.py
@@ -3,15 +3,16 @@ from .overview_page import OverviewPage
from .log_page import LogPage
class PageFactory:
- def __init__(self, out_dir, name):
+ def __init__(self, out_dir, name, content_subdir):
self.out_dir = out_dir
self.name = name
+ self.content_subdir = content_subdir
def new_commit(self, commit):
- return CommitPage(self.out_dir, self.name, commit)
+ return CommitPage(self.out_dir, self.name, commit, self.content_subdir)
def new_overview(self, branches, tags):
- return OverviewPage(self.out_dir, self.name, branches, tags)
+ return OverviewPage(self.out_dir, self.name, branches, tags, self.content_subdir)
def new_log(self, commits, branches, tags):
- return LogPage(self.out_dir, self.name, commits, branches, tags)
+ return LogPage(self.out_dir, self.name, commits, branches, tags, self.content_subdir)