-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfig.wyam
29 lines (24 loc) · 1.02 KB
/
config.wyam
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#a PersianDateTimeFormat.dll
#recipe Blog
using Wyam.Web;
using Wyam.Web.Pipelines;
// Customize your settings and add new ones here
Settings[Keys.Host] = "example.com";
Settings[BlogKeys.Title] = "سایت نمونه";
Settings[BlogKeys.Description] = "توضیح سایت";
// Settings[BlogKeys.Image] = "/assets/background.jpg";
// Pipeline Customizations
Pipelines.Remove("BlogArchive");
Pipelines.Add(new ConditionalPipeline(
ctx => ctx.Bool(BlogKeys.GenerateArchive),
new Archive(
"BlogArchive",
new ArchiveSettings
{
Pipelines = new string[] { "BlogPosts" },
TemplateFile = ctx => "_Archive.cshtml",
Layout = "/_Layout.cshtml",
PageSize = ctx => ctx.Get(BlogKeys.ArchivePageSize, int.MaxValue),
Title = (doc, ctx) => "بایگانی",
RelativePath = (doc, ctx) => $"{ctx.DirectoryPath(BlogKeys.PostsPath, ".").FullPath}"
})));