Skip to content

Latest commit

 

History

History
219 lines (167 loc) · 11.5 KB

CHANGELOG.md

File metadata and controls

219 lines (167 loc) · 11.5 KB

0.1.1 "Eccentric Wallaby"

New

  • Introduced new import keyword, which allows you to import other configuration files for different dev environments (#42)
  • Introduce new --use-drafts option to the build command, which looks for draft: true in the FrontMatter of ContentItems. Any "draft" will not have a file written to the build folder and will not appear in the collections array in Twig (#45)
  • The watch function now supports more external tools in addition to polling the file system
    • watchmedo (Cross platform pything shell utility)
    • fswatch (Cross-platform file change monitor with multiple backends)
    • inotifywait (Linux shell utility)
    • inotify (Php PECL extension)
  • Add new --profile option to show stats on time spent on each Twig template
  • Two new default FrontMatter keys have been added to all FrontMatter documents
    • filename - the full name of the file
    • basename - the name of the file without the extension
  • All data is now housed in DataItem objects that can be used for more information about the data file (#48)
  • Dynamic PageViews now support a new dataset FrontMatter key that will allow you to use DataItems in a DataSet the same way as ContentItems in a Collection (#48)
  • Introduce new select() Twig filter that will extract the values from the respective keys of an array of elements and flatten the items in addition to removing duplicate values
  • In addition to DataItem folders, ContentItem and PageView folders can now use the .example extension (#33)

Changes

  • The name on Packagist has been changed to stakx/stakx. Since there wasn't any usage, the previous stakx-io/stakx package has been deleted.
  • JailObject have been renamed to JailedDocument
  • Generic Twig runtime errors have been improved to provide more user-friendly information

Fixes

  • Permalinks with several periods or FrontMatter variables containing periods would fail to build
  • stakx now sets exit values greater than 0 when a website fails to build
  • Using watch will now compile changes to parent templates now
  • Line numbers shown in Twig errors have been corrected to be accurate
  • Assets are now copied correctly during the watch process; a notice of an undefined index of 'prefix' has been silenced
  • PageViews accessing either data or collections directly are now recompiled when the respective content is updated (#16)

Development

  • Restructured the project to be PSR-4 complaint
  • Change visibility of tracking class functions
  • Always use realpath() in FileExplorer
  • The menu Twig variable is now handled by its own class
  • All file writing has been moved to a dedicated Compiler class
  • PageManager class has been refactored to solely handle PageViews and nothing else
  • Explicit file locks aren't used for writing files anymore
  • A lot of namespaces for internal classes have been changed
  • Build settings have begun to be moved to Service singleton for global access to settings

0.1.0 "Immortal Wombat"

New

  • Added new pages variable which provides access to all static pages a stakx website has
  • The url() Twig function now accepts any PageView or CollectionItem for generating URLs
  • Data files with a .example extension are ignored (#35)
  • Errors occurring due to a file's syntax now display the path to the file to the console (#34)
  • Add Markdown Extra support
  • All generated code blocks now have the hljs class added to it

Changes

  • Ensure only JailObjects are given to Twig
  • Children of hidden parents in the menu variable are no longer accessible
  • All FrontMatter objects implement ArrayAccess
  • License file has been changed to MIT
  • The group Twig filter has been improved with several crash bugs fixed
    • If a value is not set in the Front Matter, it will be discarded in the group result
    • Grouping by booleans is now possible; a 'true' or 'false' literal will be used
  • All FrontMatter objects no longer make use of magic methods (this should have no affect on websites)
  • The menu variable only contains pages with a title FrontMatter key
  • More errors thrown contain information regarding the path of the file that triggered the error instead of just the error

Fixes

  • Fix calls to jailed functions in JailObjects
  • Parsing FrontMatter files has improved cross-platform support
  • The where Twig filter works better with null values
  • Don't crash when using watch and no theme is present
  • Nested siblings in the menu variable no longer override each other
  • An error is now thrown when an unknown collection is referenced in a dynamic PageView instead of crashing

0.1.0 Beta 3 "Repeat Stuff, Repeat Stuff, Gotta Repeat Stuff"

Bug fixes, improved Windows support, and repeaters!

New

  • Introduction of a new Repeater PageView
    • Repeater PageViews can also support automatic redirects to the permalink
  • Added support for redirecting to PageViews or ContentItems
    • By making the permalink Front Matter attribute an array of URLs instead of a single one, you will enable automatic redirects. The first element in that list will be the permalink while all the others will redirect automatically to the first link
    • Redirects can be special templates you define in your _config.yml or a generic will be used
  • Percent signs can be escaped in Front Matter now by using \ to escape it
  • Unit tests are now tested on AppVeyor in addition to Travis to test Windows

Changes

  • The menu Twig variable is now an array of PageViews instead of an array with limited information
  • FrontMatter evaluation has evolved into its own parser with supported for "expanded values"
  • All objects passed to Twig as this are now JailObjects which restrict the functions that can be called from Twig; this will prevent undefined behavior
  • Improved messages thrown by exceptions

Fixes

  • Fix broken Watch command where nothing would rebuild
  • The order Twig filter now works with PageViews
  • Fixed fenced code blocks wouldn't render as escaped HTML
  • RST include vulnerability has been fixed; everything is now jailed to the current working directory while building the website
  • Fix composer build functionality on Windows
  • Fix file paths used internally to be Windows friendly
  • Fix automatic permalink generation based on relative paths
  • this in Twig will always refer to an object now, instead of just FrontMatter (which PageView was an offender of and didn't allow functions to be called)
  • Twig error line numbers now take into account the offset of the FrontMatter in the document
  • Twig errors now show the correct relative file path instead of just the filename
  • The where Twig filter now works with any PageView type in addition to ContentItems
  • Declaring both baseurl and base in the site's configuration leads to baseurl taking precedence
  • Dates or timestamps evaluated from the date field (and the respective year, month, and day fields) in Front Matter are evaluated with respect to the timezone set in php.ini
  • Fix issue of cache creation when running from a PHAR

0.1.0 Beta 2 "The Flash"

The compile time of a website and watch command startup time has been improved drastically.

New

  • Add new summary Twig filter
  • Twig in ContentItems is now evaluated
  • The where Twig filter has a new ~= comparison for strings and arrays.
    • For strings, it will return true if the string (left) contains the needle (right)
    • For arrays, it will return true if the needle exists inside of the array
  • The where filter can now check against null
  • Markdown headers (h1, h2, h3, etc.) automatically have an ID in the rendered HTML
  • All internal manager classes now support tracking files for the watch command
  • New --no-clean option has been added to not clean the _site (target) folder on build
  • Verbose messages now show timestamps
  • Using the exclude option in configuration files now ignores files or directories instead of filtering them out
    • e.g. node_modules is ignored by default; now, node_modules will be skipped entirely instead of being scanned and later ignored during the compile process

Changes

  • Themes are now under the theme namespace for Twig templates
    • In order to extend a theme template in Twig, it must be accessed with @theme prefixed to it
  • The watch command has been marked as experimental and has been rewritten from scratch
  • Collection items are now stored by file name instead of counter-intuitive hashes
  • Permalinks are now always lowercase
  • Twig errors now display file paths instead of random hashes

Fixes

  • Don't fail when an invalid configuration file is parsed
  • The where Twig filter no longer fails with ContentItems
  • Don't crash when a theme file doesn't have either the exclude or include section

0.1.0 Beta 1

Changes

  • The base configuration file option has been superseded by baseurl and will be removed in version 1.0.0.

Fixes

  • An error message now appears with SimpleXML isn't installed; e.g. PHP 7
  • Having a base URL in the configuration file now outputs that website into that specified folder. For example, a website with a base URL of super-site will now create the website at: _site/super-site/
  • The target directory where the compiled website is now cleared at every build
  • The url() Twig function correctly outputs the base URL
  • Exceptions no longer cause the program to die
  • Errors or exception during the watch command no longer cause the program to stop watching and dying

0.1.0 Alpha 2

New

  • Add partial support for rendering reStructuredText
  • Content Items with unknown file extensions are rendered as-is

Changes

  • Front Matter variable names can only be alphabetic characters
  • The Finder Twig function now requires a parameter of where to look at

Fixes

  • Pemalinks are now sanitized and have invalid characters removed
  • Files without an explicit permalink in the Front Matter get their permalink based on their location
  • Invalid Yaml in Front Matter now stops execution
  • Front Matter special values are now re-evaluated when a dynamic page is built
    • e.g. The date field creates the %year, %month, and %day fields automatically
  • The Finder Twig function now works

0.1.0 Alpha 1

New

  • New finder Twig filter gives access to Symfony's Finder component
  • New DataItems and DataSets have been introduced
  • Add a --safe option to disable filesystem access from Twig
  • New markdown Twig filter and tag
  • Add new url Twig function to generate a URL with the base prepended
  • Add new group Twig function to group array contents based on its contents
  • Add new --no-conf option to build a website without a configuration
  • Add extremely primitive watch command to rebuild the entire website every time there's a change
  • Add new file Twig function access a file content's

Changes

  • FrontMatter variables now begin with a % instead of :
    • e.g. permalink: /blog/%year/%title/
  • Remove Laravel dependencies

Fixes

  • Looping through empty collections no longer crashes
  • PHAR archives now work with the current working directory
  • Don't crash when no PageView folders are specified

0.0.0 "It builds!"

A very early tag of stakx with only the build command mostly functional