Puput(基于 Wagtail 的博客)——文件在哪里?

Puput (Wagtail based blog) - Where are the files?

我已经将 puput 博客添加到现有的 Django 项目中。我遵循了设置独立博客应用程序的所有步骤 (https://puput.readthedocs.io/en/latest/setup.html)。

它工作正常,因为我现在在 http://127.0.0.1:8000/blog/ and can edit the content and add new posts at http://127.0.0.1:8000/blog_admin/ 上有工作博客。 但是所有文件在哪里?特别是模板文件。我在我的 Django 项目中没有看到任何新文件夹或文件。

我想编辑 html 模板以获得适合我的项目的布局。但是我找不到要编辑的文件。

我怎么能有人帮忙。谢谢!

puput 已经提供了模板 (https://github.com/APSL/puput/tree/master/puput/templates/puput),因此它们与 puput 包一起安装在您的 python 路径中。您应该可以在 /lib/site-packages/pupup/templates.

中找到它们

要更改它们不要直接从它们的安装位置编辑它们。相反,复制您要在项目中覆盖的模板,保持正确的目录结构(即 puput 的 blog_page.html 应该复制到您的 templates/puput/blog_page.html)并从那里编辑它们。