A flexible and extensible static content generation framework for .NET.
MIT License
Bot releases are visible (Hide)
Published by daveaglick over 4 years ago
ProcessSidecarFile
module to pass the media type to child modules.IBootstrapper.RunTestAsync()
extensions to assist with testing entire bootstrappers.AsDependencyOf()
methods to PipelineBuilder
.TestFileProvider
to make adding test files easier.NormalizedPath
support to TestFileProvider
internals.Published by daveaglick over 4 years ago
--debug
CLI flag to launch a debugger and attach it.Published by daveaglick over 4 years ago
HttpRequest
during retry, changed the HttpClient.SendWithRetryAsync()
and related methods to take a factory instead of a single request (#98).PipelineBuilder
with no actions to return an empty pipeline.IBootstrapper.AddDeploymentPipeline()
overloads.Published by daveaglick over 4 years ago
IReadOnlyDictionary<string, Type>
implementation to ClassCatalog
.ScriptMetadataValue
metadata caching for big performance gains in certain scenarios.IDocument
(Id
, Source
, Destination
, and ContentProvider
).ApplyDirectoryMetadata
module in favor of a more specific/powerful capability in Statiq Web (it never really made sense in Framework anyway).GenerateSitemap
document destination to "sitemap.xml".Published by daveaglick over 4 years ago
IDocument.GetParent()
overload that uses the current execution context and doesn't require passing in a set of candidate documents.GenerateFeeds
module now replaces relative links in item descriptions and content.AbsolutizeLinks
module to Statiq.Html
to turn all links in a document to absolute.Published by daveaglick over 4 years ago
ValidateLinks
module to accept Config<bool>
settings.ShortcodeResult
object that includes content and nested metadata.ShortcodeResult
(instead of Stream
and string
versions as well).ILogger
interface to IDocument
along with default implementations to support easier document logging with a document prefix (usually the source path).Published by daveaglick over 4 years ago
Markdown
shortcode to render Markdown content anywhere (for example, in another templating language like Razor).Published by daveaglick over 4 years ago
WithInputDocument()
to the EnumerateValues
module to include the original input document in the enumeration.LazyDocumentMetadataValue
.<?#^ ... /?>
as special syntax for the Include
shortcode with the "^" character.Include
shortcode for including web content.HttpClient.SendWithRetryAsync()
extension methods to send an HTTP request with a retry policy when a HttpClient
is available.IExecutionState.SendHttpRequestWithRetryAsync()
methods to send an HTTP request with a retry policy without needing an HttpClient
.ProcessIncludes
module in favor of the Include
shortcode.Published by daveaglick over 4 years ago
OrderDocuments
module will now attempt to convert incompatible values.IDocument.ToDocument()
extensions to return or clone the original object if it's an IDocument
.Published by daveaglick over 4 years ago
GenerateFeeds
module to order by descending publish date to meet feed conventions and adds a GeenrateFeeds.PreserveOrdering(bool)
method to revert to old behavior (#92).OptimizeFileName
stripping the path when optimizing the destination file name (#93).IDocument.AsDynamic()
back to an IDocument
.IReadOnlyPipelineCollection
object and exposed it via IExecutionState.Pipelines
to provide the current set of read-only pipelines during execution.IPipeline.GetAllDependencies()
extension methods to get the full set of IPipeline.DependencyOf
and IPipeline.Dependencies
for a given pipeline.IPipeline.DependencyOf
to allow specifying which pipelines a given pipeline is a dependency of (the reverse of IPipeline.Dependencies
).NormalizedPath.OptimizeFileName()
handles dashes (it no longer removes them and does a better job of collapsing them).object.ToDocument()
and object.ToDocuments()
extensions to construct the ObjectDocument<T>
from the actual type of the object.IDocument.AsDynamic()
(moved from the RenderHandlebars
module, thanks @mholo65).Published by daveaglick over 4 years ago
RenderHandlebars
module (#67, #90, thanks @mholo65).OptimizeFileName
module and added some extra configuration methods.NormalizedPath.OptimizeFileName()
as both an instance method and static helper to clean up and optimize file names for the web.ForEachDocument
and ForAllDocuments
modules to Statiq.Common so they can be used as base module classes for extensions.SetDestination
module when a string-based path is used that starts with a "." but isn't an extension.IHtmlHelper.DocumentLink()
HTML helper extensions to Statiq.Razor.CommandUtilities
in Statiq.App public.ActionFileSystemWatcher
to Statiq.Common and made it public.InterlockedBool
to Statiq.Common and made it public.ShortcodeHelper
static class to Statiq.Common and moved shortcode argument parsing helper method there.IExecutionContext
to a bunch of different extension methods that can rely on IExecutionContext.Current
.IExecutionContext.HasCurrent
to check if a current execution context is available.IExecutionContext.Current
to throw if no execution context is available.IDocument
extensions to clone documents from string or Stream
content.IExecutionContext
extensions to create documents from string or Stream
content.DocumentShortcode
and SyncDocumentShortcode
as base classes for single document-based shortcodes.ContentShortcode
and SyncContentShortcode
as base classes for simple string-based shortcodes.IMetadata.GetDocumentList()
to IMetadata.GetDocuments()
and added a new IMetadata.GetDocumentList()
that returns a DocumentList<IDocument>
.IPipelineOutputs
and IEnumerable<IDocument>
extensions to return DocumentList<TDocument>
.DocumentList<TDocument>
which wraps a set of documents, eliminating nulls, and provides an indexer for filtering destinations.IEnumerable<IDocument>.FirstOrDefaultSource()
and IEnumerable<IDocument>.FirstOrDefaultDestination()
extensions.Published by daveaglick over 4 years ago
IBootstrapper
extensions to Statiq.Common so they're available from extension libraries in an IInitializer
.IConfigurableBootstrapper
to IBootstrapper
.IInitializer
interface that can be used for library/module initialization (but only when using the Bootstrapper
).RenderRazor
module to use the built-in service collection when possible.IServiceCollection.AddRazor()
extension to register Razor services out-of-band.ClassCatalog
to Statiq.Common
and exposed it via the IExecutionState
interface..WithSource()
to the PaginateDocuments
and GroupDocuments
modules.Keys.Order
key and made the OrderDocuments
module support it.keepExisting
parameter to the GenerateExcerpt
module.IShortcodeColletion.Add()
extensions.Bootstrapper.AddShortcode()
extensions.ForAllDocuments
module that can act as a parent module to arbitrary child modules.If
shortcode (#789).ForEach
shortcode (#789).TypeHelper.TryConvert()
method that takes a target Type
.IShortcode
to return multiple shortcode result documents and concatenates their content.CreateTree
sort delegate to include the IExecutionContext
and to sort by input document order by default (instead of path/file name).IDocument.IdEquals()
extension method.IDocument.GetLink()
extension method that calls IExecutionContext.GetLink()
.IDocument.HasChildren()
extension method.OrderDocuments
that orders documents by the Keys.Index
value and then the file name by default.IConfig.Cast<TValue>()
convenience extension method.Published by daveaglick over 4 years ago
ctx
and doc
shorthand properties to the scripted metadata script host.Source
and Destination
.GenerateFeeds
by setting maximum items to 0ParseJson
module into Statiq.Core, refactored it to use System.Text.Json, and removed the Statiq.Json
extension library.IMetadata.GetNestedMetadata()
to IMetadata.GetMetadata()
.TypeHelper.RegisterTypeConverter()
methods to register type converters at runtime.IMetadata
to IDocument
.Published by daveaglick over 4 years ago
MergeDocuments
and MergeMetadata
for keeping existing metadata when merging.MergeContent
module that merges content from child modules to input documents.SetContent
module that accepts a full IContentProvider
.MetadataDictionary
initialization when items content IMetadataValue
or Config<T>
values.Paginate
module include Previous
and Next
.LazyDocumentMetadataValue
that can be used to lazily find a given document as a metadata value (I.e. after cloning).Published by daveaglick over 4 years ago
Span<char>.Replace()
extension methods.NormalizedPath.ReplaceInvalidFileNameChars()
and NormalizedPath.ReplaceInvalidPathChars()
static methods.IMetadata.GetRawEnumerable()
and an IMetadata.GetRawEnumerable()
extension method to make enumerating raw key-value pairs easier.ExecuteBranch
module that can execute multiple branches of modules.MirrorResources
and files that contain "index" in their name.FilePath
and DirectoryPath
into a single consolidated `NormalizedPath (#79).Process.WaitForExit(int)
calls (thanks @duncanawoods).Published by daveaglick over 4 years ago
IConfig
metadata values.LastWriteTime
and CreationTime
to IFileSystemEntry
.ScriptMetadataValue
.SetDestination
when using a config value to make DestinationPath
, DestinationFileName
, and DestinationExtension
take precedence (with an option to override).Context
property for the current IExecutionContext
to the available script properties (I.e., for use in metadata value scripts via "=>" notation).Published by daveaglick over 4 years ago
ProcessHtml
module for more flexible processing of DOM nodes.IEnumerable<IDocument>.Flatten()
extension to flatten document trees.IEnumerable<IDocument>.FilterSources()
and IEnumerable<IDocument>.FilterDestinations()
extension methods.FilterDestinations
module to filter documents by destination path.Config.ContainsSettings(params string[] keys)
config factory to return whether the settings contain all the specified keys.IExecutionContext
into IExecutionState
and moved implementation to Engine
.EnumerateValues
module that will clone or create documents for each item in an enumeration.Keys.ExcludeFromEvaluation
that can exclude all or some metadata values from automatic script evaluation.IMetadata.GetNestedMetadata()
to get a nested metadata value (not called IMetadata.GetMetadata()
to avoid conflicts with the old previous method of that name).IMetadata.GetMetadata()
to IMetadata.FilterMetadata()
which now returns a FilteredMetadata
instance.FilteredMetadata
class to filter underlying metadata items by key(s).CompileScript
and EvaluateScript
modules to Statiq.Core
.Microsoft.CodeAnalysis
to Statiq.Core
.InterpolateMetadata
module in favor of more robust built-in scripted metadata.Statiq.CodeAnalysis.IDocumentExtensions.Interpolate()
extension method in favor of more robust built-in scripted metadata.CancellationTokenSource
uses inside the engine to CancellationToken
since the engine does not itself cancel execution.CancellationToken
for a given execution through the IExecutionState
.IExecutionState
interface that essentially represents a run-time engine.DocumentIdComparer
to compare documents by ID (#69, thanks @mholo65).IParallelModule.WithSequentialExecution()
and standardized on .WithParallelExecution(false)
instead to make default behavior of running in parallel clearer (I.e., you have to turn it off).CacheDocuments
providing more control over when to invalidate cached documents (#78).IReadOnlyPipeline
for runtime access to pipeline data without changing modules.IExecutionContext.Pipeline
to get the currently executing pipeline from the execution context.IBootstrapper
and refactored to the one true Bootstrapper
.BootstrapperFactory
available via Bootstrapper.Factory
to create bootstrappers (this will make specialized creation extensions easier to discover).Published by daveaglick almost 5 years ago
Eval
shortcode (#37, #68, thanks @ProH4Ck)CacheDocuments
module and excludes IDocument.Id
from hash calculation (#74, thanks @mholo65)Published by daveaglick almost 5 years ago
MirrorResources
and relative links (#72, thanks @dafergu2)PhaseOutputs
collection now returns output documents from the most recent available phase or an empty result set if no phases were defined.Published by daveaglick almost 5 years ago
AnalyzeCSharp.WithCompilationAssemblyName()
to set the name of the module compilation (#71).AnalyzeCSharp
output documents to get the Roslyn Compilation
from the module (#71).IConfig.EnsureNonNull()
and IConfig.EnsureNonDocument()
extensions to simplify config parameter checks.AnalyzeCSharp
to take configs instead of atomic values.AnalyzeCSharp
contain the "ContainingAssembly" metadata (#70).build.sh
(#65, thanks @khalidabuhakmeh).Config<TValue>.MakeEnumerable()
extension to transform a config into an enumerable value.MultiConfigModuleBase
for MultiConfigModule
and ParallelMultiConfigModule
.CombineConfig
helper methods to MultiConfigModuleBase
to help with combining config values during configuration.StartProcess
configuration methods to take configs.