- If the source path is missing, the correct and useful error is now displayed
- The deprecated
srcPathis now removed, usesourcePathsto write andgetPath('source')andgetPath('sources')to read - Extra debugging for when getting a path fails
- Updated documentation and website links to their new locations
- Add a new
loadPluginsevent for use in thedocpad-plugintesterto make sure all test plugins are properly loaded beforedocpadReadyand other events are fired
- Removed superflous option aliases
outPath=>outpathconfigPaths,configPath,c=>configenvironment,e=>envlogLevel=>logrender --out,render -o=>render --output
- Removed
offlineoption, it can be re-added later if anyone uses it - Removed the last bits of docpad cloud helper functionality
- Removed skeleton functionality, just clone the repo from github instead
docpad skeleton=>docpad init(same functionality as selecting no sekleton)
- Removed version check
- Removed skeleton functionality, just clone the repo from github instead
- Updated dependencies, base files, and editions using boundation
- This will bring a massive performance boost to DocPad, especially with Caterpillar v6 which allows DocPad to disable fetching line information (a very expensive process) for log messages we don't care about
- Minimum required node version changed from
node: >=6tonode: >=10to keep up with mandatory ecosystem changes
- Prevent plugin
falsecould not be loaded errors, now it will output the path that failed to be found, as expected
- Report the correct error for missing action requests
- Ensure
docpad-plugintesterdependency is latest
- Swapped out promptly for inquirer, which brings back Node v6 support (regression since v6.82.1)
- Close issue #1093
- Add logging support to the pluginloader to make debugging plugin resolutions easier
- Fixed failures of plugin loading and creation not being reported correctly
- Ensure all dependencies are the latest right now, to help fix false negatives in plugin resolution
- Close thread #248
- Fixed initialising new projects (regression from v6.82.0)
docpad initwill now prompt for skeletons (before v6.82.0 this was done viadocpad skeleton, which was removed)- Upgraded remaining dependencies
- Upgraded
promptlydependency from v2 to v3 - Swapped
superagentfornode-fetch - Close issue #1091
- Upgraded
- This release focuses on eliminating the situation where DocPad would initiate with invalid configuration that would then need to be overwritten later, this could cause plugins to not load correctly, invalid configuration persisting, and general instability until the correct configuration was loaded. Now the correct configuration is loaded from commencement.
- Due to new dependency requirements, the minimum supported Node version is now Node version 6, which drops support for Node versions 0.10, 0.12, and 4.
- Closes issue #1086
- Fix DocPad not working on windows (regression since v6.81.0)
- Closes issue #1088, thread #240, issue #1085, issue #1084
- Progress indicator will now pause once the action has completed, and resume on new actions, this allows for cleaner shutdowns with no change of ability
- Graceful shutdown is now offered by the
destroyOnExitconfiguration option, which usesprocess.on('beforeExit', docpad.onBeforeExit)to destroy DocPad gracefully. This is now possible as we don't have to support Node 0.10. Before we had to do graceful shutdowns in a more complex and manual manner, which resulted in less graceful shutdowns. - DocPad will now longer output
The action completed successfully., as unless an error has displayed, then evidently everything remains successful - Debug log file will now only be removed if it needs to be replaced with another one
- Fixed
--no-colorCLI argument andcolorconfiguration option not working- Closes issue #938
- Color now correctly defaults to environment support
- Also now supports
--colourand--no-colour - Removed
--promptsCLI argument andpromptsconfig option in favour of the--progressCLI argument andprogressconfig option (as that is allpromptsdid really)
- The CLI has been rewritten and simplified
- The
commanderpackage has been swapped out for thecacpackage- Closes issue #1048
- Customisation of the out path via a CLI option now occurs via
--outPathto remove ambiguity withdocpad renderout file customisation - Introduced
--verboseand--debugCLI options, such that one can do--silent --debug - For
docpad renderthere is no longer a delay to check for stdin, however if you are using stdin, you must now provide the--stdinCLI argumentstdinreading abilities has been moved into the docpadrenderStdinmethod, andrenderhas gained support for it, as well as support for writing an output file
- Global CLI options are now parsed before DocPad is instantiated, to ensure configuration is correct from initiation, rather than incorrect at instantiation then made correct later
- This removes built in support for customising this, however, no one should be customising global CLI options anyway
- As expected,
consoleSetupevent fires after DocPad is ready, and commands can be added to thecacinstance in the event options- CLI commands are executed after this event resolves
- The
- Configuration parsing improvements
- Paths will now be resolved when requested, rather than having their resolutions cached, this results in more reliable path resolution across configuration changes
- Fixed user configuration never actually being applied (regression since v6.80.1)
- Fixed user configuration never loading if it was in your home folder yet you had Dropbox present
- Closes issue #799
- Fixed the loaded user and env configuration debug messages still saying loading
- The method
loadConfigPathnow receives a string as its first argument - The method
getConfigPathhas been replaced with the newgetPath('config') - Leftover DocPad configuration and Plugin configuration will now be correctly removed, before it would linger due to new configuration always being merged into the old, now new configuration swaps out the old
- Plugins are now determined via your project's
package.jsondependencies, rather than scanning thenode_modulesdirectory- This new approach is dramatically faster, and also allows us to concisely warn on plugin skips
- Closes pull request #903
- This new approach is dramatically faster, and also allows us to concisely warn on plugin skips
- Instantiation has removed unneeded complexity (and paired with the aforementioned CLI changes) this ensures DocPad always results in a valid state
- Removed the configuration option
loggersthat allowed users to swap our caterpillar for something else- No one used it, nor is it optimal to do so. It just introduced a lot of unnecessary complexity and fragility
- Removed the method
setLoggers
- Constructing DocPad will now always perform the
loadandreadyactions- Removed the construction option
actionthat allowed one to override the initiation actions - Removed the
docpadLoadedevent. It was poorly named, non-optimal, and only used by a single outdated plugin.
- Removed the construction option
- Fixed
docpad cleannot cleaning a customoutPath- DocPad now also outputs which paths were cleaned
- Path cleaning now uses a more robust way of ensuring DocPad doesn't clean a parent outPath
- Closes issue #727
- Removed the configuration option
- The Plugin Loader class has been abstracted out to pluginloader and made generic
- Removes
require('docpad').PluginLoaderuserequire('@bevry/pluginloader')instead - Removes the methods:
loadPluginsIn,loadedPlugin - Removes the configuration options:
pluginsPaths,enableUnlistedPlugins,skipUnsupportedPlugins,warnUncompiledPrivatePlugins,enabledPlugins - Closes issue #391
- Removes
- Removed the
--forceCLI option, it was unnecessary customisation- Simplified the installer methods:
initGitRepo,initNodeModules,installNodeModule,uninstallNodeModule
- Simplified the installer methods:
- Removed some long standing deprecations
- Removed
require('docpad').BasePluginuserequire('docpad-baseplugin')instead - Removed
require('docpad').createInstanceuserequire('docpad').createinstead - Removed
docpadUtil.setImmediate(existed for node 0.8 compat which hasn't been there since DocPad 6.72) usesetImmediateinstead
- Removed
- Renamed
docpad.inspectortodocpad.inspectand removeddocpadUtil.inspect - Removed the unstable node.js version warning from DocPad v6.55.6
- Removed leftover
.babelrcfile that was causing everything to be compiled againstes2015instead of what we desire from ourpackage.jsonconfiguration - Updated base files and editions using boundation
- This release accomplishes the removal of some long standing deprecations, for background reading refer to:
- Deprecating In-Memory DocPad Importers & Exporters
- Abstract out Server functionality into pluginland
- Operation Disassemble & Diversify
- To maintain static server functionality, install the
serveplugin
- Changes:
- Added
runBeforeandrunAfterevents - DocPad is now verbose about when it has to perform an mtime change
- Added
- Migrations / Removals:
- Progress on issue #691 and issue #391
- Abstracted out base plugin into docpad-baseplugin
- Abstracted out testers into docpad-plugintester
- Close issue #1081
- Removed the deprecated dynamic server abilities
- Abstracted out the static server abilities into the new
serveplugin - Removes the properties:
serverExpress,serverHttp,filesByUrl,filesBySelector,filesByOutPath - Removes the methods:
getServer,setServer,destroyServer,getFileByUrl,getFileByRoute,getPort,getHostname,getServerUrl,getSimpleServerUrl,serverDocument,serverMiddlewareHeader,serverMiddlewareRouter,serverMiddleware404,serverMiddleware500,server - Removes the events:
serverBefore,serverExtend,serverAfter - Removes the options:
databaseCachePath,port,hostname,maxAge,serverHttp,serverExpress,extendServer,middlewareStandard,middlewareBodyParser,middlewareMethodOverride,middlewareExpressRouter,middleware404,middleware500 - Removes the document properties:
dynamic templateData.site.urlwill now default to an empty string- Removes the
docpad-serverexecutable, and thedocpad serveraction- Use
docpad runwith theserveplugin instead
- Use
- Removed the deprecated ability to load uncompiled plugins
- Removed the deprecated DocPad database cache, it never worked well
- Removes the properties:
databaseTempCache - Removes the methods:
getDatabaseSafe - Removes the
generateevent properties:cache
- Removes the properties:
- Removed the deprecated
docpad-compileexecutable, no one used it - Removed leftover
hashKeyproperty
- Progress on issue #691 and issue #391
- New Deprecations:
require('docpad').require('testers')will be removed in an upcoming release- Use
require('docpad-plugintester')instead - A warning will be outputted
- Use
require('docpad').BasePluginwill be removed in an upcoming release- Use
require('docpad-baseplugin')instead - No warning will be outputted
- Use
require('docpad').require('thing')now only supports the thingtesters
- Updated base files and editions using boundation
- Close issue #1085
docpad rendercommand now behaves as expected, and omission of the filename now shows the error that before failed to report- Fixes the
ERR_INVALID_ARG_TYPEerror when using stdin- Closes issue #1082
- Fixes the
- DocPad now shuts down much more gracefully and comprehensively
- Closes issue #1042 and issue #988
- Fixed failures not being represented in the exit code
- Closes issue #1039 and issue #817
- Fixes active requests and active handles from being outputted on shutdown when not needed
- Closes pull request #1038
- Fixed
ENOTCONNerror from being outputted when not necessary- Closes pull request #1029 and issue #1028
- Signal interrupt (ctrl+c) shutdowns now occur more gracefully and set the exit code appropriately
- The first signal interrupt will queue a shutdown
- The second signal interrupt will commence a shutdown immediately
- The third signal interrupt will terminate completely
- Closes issue #698
- Errors that occured before the locale was ready are now reported
- Required precompiling the locale, as such it has moved from
locale/en.csontosource/lib/locale/en.coffee - Closes issue #1012
- Required precompiling the locale, as such it has moved from
- DocPad shut downs are now quicker by default (1 second quicker)
- Shutdown delay was reduced and made customisable via the new
destroyDelayconfiguration option
- Shutdown delay was reduced and made customisable via the new
- Errors will now report their causations thanks to Errlop
- Closes issue #1017
- For DocPad users and plugin developers, if you ever need to make timers/timeouts/intervals, please use
docpad.timerto make and destroy them, that way DocPad can ensure they are cleaned up so they don't prevent shutdown consoleSetuperrors are now reported correctly- Uncaught exceptions are now fatal errors by default, which will cause DocPad to shut down
- DocPad will now no longer output
The action completed successfullywhen something went wrong with the action - Removed the internal methods
docpad.destroyRegenerateTimer,docpad.createRegenerateTimer,docpadUtil.wait,consoleInterface.destroy - Introduced the configuration options
catchOurExceptions,catchUncaughtExceptions,setExitCodeOnFatal,setExitCodeOnError,setExitCodeOnRequest,destroyDelay,destroyOnSignalInterrupt,regenerateDelay,slowFilesDelay,slowPluginsDelay - Added locale strings
destroyDocPad,destroyedDocPad - Updated dependencies
- Abstracted out the document matter parsing into the docmatter package, which DocPad now consumes
- Closes issue #389
- Progress totals are now accurately reflect item completions
- progressbar has been replaced with progress-title
- This is far more robust and simple, offers greater and more detailed progress updates (ie. progress updates for file system watching), and even supports progress updates inside DocPad's debug mode
- Fixed progress bar sometimes lingering after a generation
- Closes issue #1080
- Updated dependencies
- Fixed
Error: extendr only supports extending plain objects, an input was not a plain objectwhen scaffolding a new project (bug introduced in v6.80.0)- Closes issue #1079
- If a task completed, but had already completed earlier, you will now get more detailed debugging information to help you locate the cause
- Updated dependencies
- Fixed
Buffer() is deprecated due to security and usability issues- Closes issue #1078
- Fixed
Cannot set property initialConfig of #<LessPlugin> which has only a getter- Closes issue #1077
- Huge thank you to the sponsors who supported this release. It really did help.
- Leave feedback here
- Removed all non-vital cloud communication
- Closes issue #1041 and issue #1037
- Removed
docpad-debuganddocpad-traceexecutables, as there are now more modern ways of debugging - Updated dependencies
- Closes issue #1063
- This is a beta release, while it is in beta, assume there will be breaking changes
- DocPad is now compiled with CoffeeScript v2
- To use it with CoffeeScript v1 plugins, you will need to set the following environment variable
EDITIONS_SYNTAX_BLACKLIST=esnext- You can do this on unix systems by running DocPad like so:
env EDITIONS_SYNTAX_BLACKLIST=esnext docpad run - Otherwise you will encounter
TypeError: Class constructor BasePlugin cannot be invoked without 'new'
- You can do this on unix systems by running DocPad like so:
- To upgrade your plugin to v2, run boundation on it
- If you use optional arguments in your plugin or event functions, such as
fn (opts={}, next)then it must be changed tofn (opts, next)as otherwise the completion callback will not be passed, as thefn.lengthwill be0and ambi will not be able to detect it is an asynchronous function - details
- To use it with CoffeeScript v1 plugins, you will need to set the following environment variable
- Turns out dynamic documents always had invalid content types
- As dynamic documents are a deprecated feature, the setting of the malfunctioning header has been removed, and a warning is now outputted when they are used
- Configuration loading is merged more accurately - details
- Logger references are now removed when they are destroyed, and if logging occurs without loggers, the message will be outputted to the console (unless it seems to be a debug message, in which case it will be outputted only if you are not debugging)
- stdin errors changed to log level 6
- Removed DocPad's custom
--profilehandling, as there are now more modern ways of debugging node apps - Removed
safeModeoption as it was never implemented completely - Internal
TaskGroupproperty on models has been renamed to the more appropriatecreateTaskGroup - Updated dependencies
- closes
- major benefits are offered by these upgrades:
- extendr - object merging is now more reliable
- taskgroup, caterpillar, watchr, scandirectory - huge performance increases and reliability, should be about 50%
- thread on taskgroup performance
- caterpillar performance comes from a more streamlined logging process, before there was some redundant effort
- watchr and scandirectory have had a near complete refactoring, as well as implemented the super fast readdir-cluster
- these deps were not upgraded:
- express - requires a future DocPad v7 - details
- promptly - drops support for earlier node versions that DocPad still supports
- superagent - drops support for earlier node versions that DocPad still supports
- Fixed DocPad having stdin errors on exit under certain circumstances
- Thanks to Craig Smith for issue #1049
- Updated base files
- Fix the
this.emitSerialerrors when running plugin tests- This was due to event-emitter-grouped v2.5.0 busting joe v1.6.0 which we pinned, so pinned joe to
~1.6.1and joe-reporter-console to~1.2.1
- This was due to event-emitter-grouped v2.5.0 busting joe v1.6.0 which we pinned, so pinned joe to
- Fix
out/lib/testers.jsbeing omitted in published package (regression since v6.79.1)- Without this file plugin tests break, so this fixes that
- Fix
src/being included in published package (regression since v6.79.1)- This reduces package size once again
- Thanks to Sebastian Domagała for his assistance
- Updated base files
- This prefixes DocPad's own
./package.jsonscripts withour:to prevent npm v4's use ofpreparefrom causing DocPad installs to fail under development conditions
- This prefixes DocPad's own
- Thanks to Sebastian Domagała for his assistance
- Bumped coffee-script dependency version
- Fixed possible
docpad not definedissue onloadLocale
- Set joe version to fixed 1.6.0 and event-emitter-grouped to 2.4.3 to handle issue 1047
- Recompiled with latest dev dependencies
- Fixed missing
nextparameter for methodsfixNodePackageVersions,installNodeModuleanduninstallNodeModule.
- Fixed
path option is deprecatederror when cloning a skeleton- Thanks to Gabriel Ignisca for issue #1016
- Changed donation message, maybe this one will be more successful
- Updated dev dependencies
- Updated base files
- Consolidated server address code
- DocPad will now output both the original server address and the simplified server address if they differ, background:
- Profilers must now be specified by
DOCPAD_PROFILERvariable - Prevent waiting handles from being outputted in silent mode (prevents a common render test failure)
- Use hostenv for
PORTandHOSTNAMEvariables - Listen to
0.0.0.0hostname by default (will be outputted aslocalhost) - Updated dependencies
- Updated base files
- Fixed
queryEngineis undefined error (regression since v6.78.1)- Thanks to wlbrough for issue #943
- You can now
module.exports = function(docpad){ return {/* your docpad configuration */} }
- Better error reporting when a custom collection is invalid
- Thanks to Simon Smithies for issue #875
- Replaced
lodashwithunderscore- Backbone (our dependency) already includes
underscore, so makes sense to reduce our footprint
- Backbone (our dependency) already includes
- Removed these deprecated exports:
require('docpad').DocPadrequire('docpad').Backbonerequire('docpad').queryEnginedocpadInstance.View
- Added
progressconfiguration option that you can use to disable progress bars
- Fixed testers wanting chai (regression since v6.76.0)
- Regenerate timer is now closed correctly (regression since v6.48.0)
- Close stdin after destroy when using the console interface
- Output anything we could be waiting for after destroy using the console interface
- Rather than including all of lodash, we now just include the modules we need
- Updated profiling for the latest tools
- Quicker execution of certain spawned commands
- Updated dependencies
- Better error handling when updating user config fails
- Better error messages when CSON handling fails
- Better input availability detection
- Better CSON config and meta parsing
- Updated dependencies
- Updated for latest exchange and docpad package info retrieval
- Fixed
--profile- Thanks to Zearin, fengtingzhang for issue #937
- Fixed
--skeletonoption not working- Fixes issue #942
- Removed
skeletoncommand, use theinitorruncommands instead - Removed
enginesfrominit'spackage.json - Updated dependencies
- Updated most dependencies from
~to^ - Released live: https://plus.google.com/events/cc41smt4r608vj8fdrjp7a1jqbg
- Fixed
TypeError: undefined is not a functionunder some circumstances- Thanks to Dimitar Kolev-Dick and Lisa Williams for issue #935
- Only display prompts and check for updates when we are in an interactive terminal by default
- Improved debugging of TaskGroups
- Fixed crash when MAC was not available (regression since v6.72.0)
- Fixes Travis CI problems, hopefully fixes Heroku Problems
- Fixed changed log level configuration not applying in subsequent configuration updates (regression since always?)
- Fixes warnings appearing in CLI render commands (regression since always?)
- Better
createandcreateInstancemethods (inspired from TaskGroup's) - Better expectation tests that now show differences
- Fixed CLI tests using old DocPad (they now use
--globalflag) (regression since always?) - Updated dependencies
- If an error occurs during the initialisation actions, DocPad will only suicide if there was no completion callback to handle the error
- More robust way of writing errors in case
stderrdoesn't exist or isn't writeable
- Fixed DocPad creation via API returning
2(regression since v6.71.0)- For some reason, having
DocPad::inspectdefined broke it, as suchDocPad::inspectis nowDocPad::inspector
- For some reason, having
- Fixed double binding of some prototype methods
- Simpler
DocPad.createandDocPad.createInstancefunctions - The
--no-coloroption now works (introduced in v6.71.0)
- Got rid of the
main.coffee/main.jsfile, our new main file is the DocPad class itselflib/docpad - Updated dependencies
- Fixed possibility of DocPad not exiting on exiting on a error
- More robust error writing
- jshint compliance
- Fixed fetching of skeletons (regression since v6.70.0)
- Thanks to Kasper Souren for issue #930
- Added the ability to uncompiled warn warnings off for private plugins by setting
warnUncompiledPrivatePluginstofalse- Thanks to Dimitar Kolev-Dick for issue #928
- Added better warnings when loading a plugin fails for whatever reason
- Better reporting of warnings
- coffeelint compliance
- Updated dependencies
- Output
127.0.0.1as the hostname when IPv6 addresses::and::1are reported - Output
127.0.0.1as the hostname instead oflocalhostwhen0.0.0.0is reported
- Updated
docpad-debugto work with latest debugging tools - DocPad will now output most things with colours when it is able to
- Thanks to Zearin for pull request #834
- Fixed
TypeError: Object #<CSON> has no method 'parseCSON'error when parsing user configuration (regression from v6.70.0)- Thanks to Kasper Souren for pull request #921 and issue #917
- Fixed secondary URL redirect
- Thanks to shawnzhu for pull request #905 and issue #850
- Fixed incorrect writing of user configuration (regression from v6.70.0)
- Thanks to Pavan Gupta for pull request #922
- Re-added support for uncompiled plugins (regression from v6.70.0)
- Thanks to Zeno Rocha for issue #918
- When an error occurs with the
docpad.actionAPI and a completion callback is specified, the error will no longer be logged - Fixed reporting of errors when something goes wrong when initialising a selected skeleton
- Fixed potential crash under random circumstances caused by 3rd party dependency
- Also removed the [longjohn] package as a precaution for when caterpillar can't fix the issue
- More information on issue #926
- We now output
localhostinstead of0.0.0.0- Thanks to paleite and Stephen Brown II for issue #911
- Added support for Node 0.12 and IO.js
- Dropped support for Node 0.8. Minimum supported Node version is now 0.10.
- CSON has been updated to v2, this means that your
docpad.csonfiles will no longer work with functions- If you have functions inside your
docpad.csonfile:- Rename
docpad.csontodocpad.coffee - Export your configuration inside
docpad.coffeeby doing:module.exports = {your configuration data} - Example
docpad.coffeefile.
- Rename
- If you have functions inside your
- Updated dependencies
- Better id deletion when cloning a model
- Thanks to Nathan Friedly for pull request #893
- Fixed incorrect
layoutSelectorundefined error when DocPad can't find your layout- Thanks to Nathan Friedly for pull request #897
- Updated dependencies
- Fixed a TOS issue
- Thanks to plfannery for pull request #884
- Updated dependencies
- Updated dependencies
- longjohn is now an optional dependency, as for some people it was not loading, also made it use ~ instead of ^ as maybe those users are using old npm versions
- File and document messages are now localised
- Better error messages when parsing the meta data fails
- Will now output an error when a document or file model was instantiated outside of
docpad.createModelas instantiating directly will mean they will be missing necessary properties and events
- We now output the link to the bug report guide with error messages
- We now include longjohn in debug mode for better stack traces
-
Meta header separators can now contain additional characters, providing there is still a character that repeats at least 3 times
This allows you to do things like:
/* --- works: "yes" --- */ window.alert("<%- @document.works %>")Or even more concisely:
/*** works: "yes" ***/ window.alert("<%- @document.works %>")
- Independent rendering (including layout rendering) now occurs on a clone, allowing independent renderings on the same file to occur at the same time
- This fixes an issue where a recursive render on a file will cause a stalemate
- More detailed errors when something goes wrong with rendering a file
- Deprecated
docpad.cloneModel(document), you can now usedocument.clone()safely - Deprecated
applyoption fordocument.render, now usedocument.clone().action('render')instead - Fixed broken
docpad.addModelanddocpad.addModels(broken since their introduction in v6.55.0) - Updated dependencies
- Added donation plea for bevry/meta#3
- Updated dependencies
- Fixed cache file not being correctly (regression since v6.63.7)
- Thanks to Ivan Klimchuk for pull request #825
- Fixed a possible issue with
@includetemplate helper not working when therenderPassesconfig option changes - DocPad will now auto-set the
site.urltemplate data to the calculated site URL (e.g.http://localhost:9778) if it is falsey- This allows you to do
environments: development: templateData: site: url: falseinside your DocPad configuration files, to always use the correct site url regardless of environment
- This allows you to do
- Fixed "Object # has no method err" (regression since v6.37.7)
- Fixed IE9 and below not understanding the charset we send
- Thanks to Eric Vantillard for issue #801
- Better debugging for invalid watch states
- For more information see issue #792
- Fixed DocPad failing to serve files after the initial generation once the docpad configuration file has been modified
- Thanks to Michael Williams for issue #811
- Updated dependencies
- Fixed npm v1.4.3 from using
^instead of~when installing and updating docpad plugins
- Fixed invalid TaskGroup
~3.3.7ndependency version (regression since v6.63.1)- Thanks to Jens Wilke for issue #806
- Don't use HTTPS URLs for fetching latest version and exchange data (as HTTPS URLs may not always be available)
- Updated dependencies
- Regenerate every options are now customisable via
regenerateEveryOptions - Regenerate every options now default to
partial:false, populate:true- Before there were no defaults, meaning that they always did a non populating, partial, regeneration (regression exposed due to the fix in v6.61.0)
- Don't show generate success message if an error occurred
- Fixed gobbling of error messages during
contextualizeFiles,renderFilesorwriteFiles(regression since v6.59.2)- Thanks to Rob Loach, Nathan Rijksen for issue #784
- All task groups and tasks we define are now named (makes for easier debugging)
- Updated dependencies
- Disabled database writing by default (set
databaseCachetofalseinstead of'write"by default)- We never used it, still many nuances with reading to figure out, so it doesn't make sense incurring the performance penalty of the write while there is no use for it
- Enable writing manually by setting
databaseCacheto"write" - Enable writing and reading manually by setting
databaseCachetotrue
- Stylesheets are more efficiently generated
- Files with the
outExtension: 'css'are now the only ones included in thestylesheetcollection - Stylesheets no longer have
referencesOtherstotrueon them by default, this is now left up to plugin authors to do - Thanks to Dimitar Kolev-Dick for issue #789
- Files with the
- Fixed regeneration always regenerating everything (regression since v6.58.0)
- Thanks to Dimitar Kolev-Dick, Marcus Stong for issue #785
- Implemented
304 Not Modifiedheader - Fixed some
dateandstaterrors (regression since v6.60.0)- Thanks to Anton Wilhelm for pull request #787
- Thanks to Ivan Klimchuk for pull request #781
- Fixed
toUTCStringerrors (regression since v6.60.0)
- Don't include
--save-devwhen installing plugins (regression since v6.59.3)
- Updated dependencies
- Added
etag,cache-control,last-modified,date, andcharsetheaders- Thanks to Marcus Stong for issue #740
- Non-CoffeeScript plugin testers can now rejoice, you can now easily extend the tester classes by using
TesterClass.extend({})- Thanks to the extendonclass module
- Non-CoffeeScript plugin authors can now rejoice, you can now easily extend the
BasePluginclass by usingvar MyPlugin = BasePlugin.extend({})- Thanks to the extendonclass module
- Added a warning when trying to set the
idattribute manually- Thanks to Piotr Zduniak for issue #742
- Fixed uninstalled dev dependency plugins (e.g. livereload), from being reinstalled on the next install
- Thanks to Alan Languirand, Eduán Lávaque for issue #744
- More reliable delay of requests while the initial generation is still performing
- Removed the deprecated
writeSourcemeta data header,writeSourceis now only available via the API usage - Added new
generatedevent that will fire once the initial generation has completed
- Fixed listening on heroku (regression since v6.58.2)
- Removed the deprecated
ensureFile,ensureDocument,ensureModel/ensureFileOrDocumentmethods, useaddFile,addDocument, andaddModelinstead - Improved watching, should hopefully fix #738, #742, #739
- Updated dependencies
- Can now change the hostname that we listen to via the
hostnameconfiguration option- Thanks to Dario for pull request #737
- Updated dependencies
- Output of change detections is now an
infolog level, instead ofdebug, allowing you to see what is going on by default - Fixed regenerations triggered by changed files not working (regression since v6.58.0)
- Thanks to Fryderyk Dziarmagowski, Anton Poleshchuk, Eduán Lávaque for issue #738
- Deprecated and removed the
parseBeforeandparseAfterevents- Files are now parsed as they are loaded in, rather than only when they reach the generation cycle
- See issue #736 for discussion and upgrade options
- Dynamic documents now have access to templateData that plugins have extended (regression since always)
- Dynamic documents now go through the standard generation process
- Thanks to Steve McArthur, Marcus Stong for docpad/docpad-plugin-feedr#5
- Documents that want to be rendered, but not written, are now rendered (possible regression since v6.55.0)
- Thanks to pflannery for issue #734
- Moved the missing layout error check from contextualize step to render step, as the layout may not be there if we are still loading documents
- Contextualize will now also be called during a file's
loadaction to help injected files being contextualized
- Updated dependencies
- Fixed delay of requests not working when documents are still performing their initial generation (regression since v6.57.0)
- Improved the caching of on-the-fly collections and fixed the name setting of collections
- Possible b/c break:
DocPad::getCollections()will now return an[collection, ...]array, rather than an{name: collection}object. To get the name of a collection, you should now docollection.options.name
- Possible b/c break:
- The database cache introduced in v6.55.0 is set to
write(write-only) by default now until we fix out the kinks- To enable read mode, use the
--cachecommand line option when running DocPad, or set thedatabaseCacheconfiguration option totrue
- To enable read mode, use the
- Properly fixed v6.55.3 issue while maintaining node.js v0.8 compatibility
- Thanks to Michael Duane Mooring, pflannery for issue #717
- Fixed Node.js v0.8 compatibility (regression since v6.55.3)
- ??? was already published...
- Output a huge warning banner when running DocPad against an unstable version of Node.js
- Fixed
Configuration changes require adocpad cleanto regenerate files(regression since v6.55.0)- Thanks to Christo Buschek for issue #718
- Fixed
Offline changes to layout do not re-render the layout's children(regression since v6.55.0) - Removed
layoutIdinternal file attribute in favour of newlayoutRelativePathinternal file attribute - Added
hasLayoutspecial collection docpad updatewill now also performdocpad cleanfor you to ensure the database cache is cleaned between versions
- Fixed possible "(node) warning: Recursive process.nextTick detected. This will break in the next version of node. Please use setImmediate for recursive deferral." error under certain circumstances (regression since always?)
- Thanks to Michael Duane Mooring for issue #717
- Fixed
Changes to layout do not re-render the layout's children(regression since v6.55.0)- Thanks to Urs Hunkler for issue #716
- Fixed
databaseCacheconfig property (introduced in v6.55.0)
- DocPad will now cache the database to
.docpad.dbafter generation, and load it up upon initial generation- This removes the huge performance burden of the initial scan, load, parse, render
- The
writeSourceattribute can now be considered under review for deprecation - This can be turned off by setting the configuration option
databaseCachetofalse - You can customise the path of the database cache file via the
databaseCachePathconfiguration option - The database cache will be cleared on
docpad clean - NOTE: If you remove files when DocPad is shut down, DocPad will not pick it up the changes, to fix do one of the following:
- Run
docpad cleanto reset the database cache - Disable the database cache by setting the
databaseCacheconfiguration option tofalse - Or just make sure when you are working on your DocPad site, you have
docpad runrunning - This potential problem is planned on being fixed in a later version, for now an immediate release with these huge performance gains far outweigh a delayed release with the fix
- Run
- DocPad will now only re-render things that have explicitly changed or not been written yet
- This removes a huge performance burden when pulling in virtual documents
- To use this when importing documents, make sure you set the
mtimeattribute
- Added
--silentoption that setsprompts: falsefor disabling all prompts- Removed
-soption that was an alias for--skeletonto avoid confusion - Thanks to Christo Buschek for issue #715
- Removed
- The following changes have been made to the
DocPadprototypeaddModel(model, opts)was addedaddModels(models, opts)was addedcreateModels(models, opts)was addedensureModel(model, opts)is now the same ascreateModel(model, opts)generatePrepare,generateLoad,generateRender,generatePostpare,populateCollectionswere consolidated intogenerate(opts, next)
- The following changes have been made to the events:
generateBefore,populateCollectionsBefore,populateCollections,generateAfternow receive the options:initial,reset, andcollection
- The following changes have been made to the models:
rtime(render time),wtime(write time) attributes have been addeddate,mtime,ctime,rtime,wtimeattributes if set will always be Date instancesactionmethod has been addedload,parse,contextualize,render,write,writeSourceshould now be called viafile.action('the action name', opts, next)instead
- Updated dependencies
- Fixed
Cannot read property 'id' of undefinederror when adding nothing to a block- Thanks to Māris Krivtežs, Eduán Lávaque, Bruno Heridet, pflannery for issue #710
- Updated dependencies
- Fixed custom server configuration being ignored
- Thanks to andresberrios for issue #712
- Fixed
TypeError: Cannot read property 'encoding' of null- Thanks to Tony, Eduán Lávaque for issue #711
- Fixed meta data not resetting correctly
- Thanks to Māris Krivtežs, Eduán Lávaque for issue #710
- Updated dependencies
- The
removeWhitespaceandcontentRemoveRegextester config options now make sense- They are now executed against the value we are comparing, rather than on all the values in serialised form
docpad installwill no longer updategit,http,httpsand other remote dependencies- Thank to pflannery for pull request #701
- Fixed background task error reporting (regression since always???)
- Fixes
RangeError: Maximum call stack size exceedederrors - Fixes error reporting for failed partials
- Error reports during renders will now always output the error message
- Thanks to Michael Duane Mooring, pflannery, Nathan Friedly, ofShard for issue #692
- Fixes
- Fixed template helpers not being able to reference other template helpers
- Better debugging support due to name tasks and task groups
- Updated dependencies
- Much more detailed progress bars
- Updated dependencies
- Fix incorrect
@latestwithinnpm install docpad@6 @latest --savewhen runningdocpad updateanddocpad install- You'll probably want to run
npm uninstall --save latestto make sure that the incorrectly installedlatestdependency is removed
- You'll probably want to run
- Fix plugin version check
- Thanks to unframework for pull request #690
- Fix
TypeError: Cannot read property 'stack' of undefinederror- Thanks to pflannery and Moritz Stefaner for issue #686
- DocPad version information will now output the directory path of which DocPad instance is loaded
- Thanks to pflannery for pull request #687
- Backwards compatibility change: Notifications are now handled by plugins instead of the core
- So if you like notifications, you'll probably want to install the growl plugin
- Thanks to Bruno Heridet for pull request #605
- Backwards compatibility change: i18n support is now handled via the
encodingandiconvlitedependencies instead oficonv- This enables windows support for i18n
- Just like before, you turn on i18n abilities by setting the
detectEncodingconfiguration option totrue(stillfalseby default) - Thanks to Sim Jiason and Eduán Lávaque for issue #627
- Added
renderCollectionBeforeandrenderCollectionAfterevents- Thanks to Bruno Heridet for pull request #608
- Fixed the
connect.multipart() will be removed in connect 3.0warning- Replaced the
bodyParsermiddleware with theurlencodedandjsonmiddlewares
- Replaced the
- Added
404 Not Foundnotices to the console- Thanks to telekosmos, Eduán Lávaque and pflannery for issue #677
- Updated dependencies
- Fixed DocPad version being undefined in some instances causing plugins to skip (regression since v6.53.3)
- No need to load in the DocPad
package.jsonfile each load - We now output whether or not we are a global or local installation with
docpad --version- Thanks to Henrik Cederblad and Eduán Lávaque for issue #672
- Watching improvements
- Updated dependencies
- Fixed
ReferenceError: config is not definedon subscribe (regression since v6.53.0)- Thanks to Igor and Alberto Leal for issue #663
- Fixed autodetection of name and username (regression since v6.53.0)
- Updated dependencies
- Absolute paths should no longer end up joined when the configuration is reloaded
- Improved locale support
- Can now merge locales together
- Fixes subscribe and tos metrics
- We now load the user information within the
loadaction, rather than inside thereadyaction - Closes issue #623
- We now load the user information within the
- Possible fix for
Error: A task's completion callback has fired when the task was already in a completed state, this is unexpectederror- Thanks to Ryan Fitzer for issue #643 thanks to
- Thanks to drguildo, Evan Bovie, Brandon Mason, ashyadav for issue #623
- Will now output the progress of
iconvinstall ifdetectEncodingis true andiconvisn't installed - Updated dependencies
- Fixed "structure already exists" errors after successful
docpad initanddocpad skeletoncompletion (regression since v6.51.0)- Thanks to Eduán Lávaque for issue #631
- Better errors when a skeleton fails via the global
docpad run
- Pay more attention to getmac errors
- Ensure completion callback (when specified) is always fired for the
DocPad::errorandDocPad::trackmethods - Fixed
DocPad::getBlocksreturning the DocPad instance instead of the blocks- Thanks to Bruno Heridet for pull request #612
- Added
DocPad::getIgnoreOptsmethod to help clean up some code- Thanks to Bruno Heridet for pull request #611
- Removed all calls to
process.exitby instead destroying DocPad properly causing an automatic shutdown if that is what is desired - Fatal errors are now written to stderr instead of stdout
- Updated dependencies
- When using writeSource don't write the header if there is no meta data
- Added support for
writeSource: "once"
- Fixed syntax errors in docpad configuration file not being reported correctly (regression since v6.49.0)
- Thanks to drguildo for issue #623
- If a configuration file fails to load we will now tell you which one it was
- Fixed
TypeError: Cannot call method 'getLocale' of undefinedwhen destroying (regression since v6.49.0)
- Fixed
docpad uninstall <pluginName>(feature introduced in v6.51.0)
- Fixed certain plugin tests that require skeleton initialisation (regression since v6.52.0)
- When using
--globalflag we won't kill the global instance when starting a skeleton
- Fixed
docpad upgrade
- Better upgrade
docpad upgradeand updatedocpad updateexperience- Thanks to drguildo and Eduan Lavaque for issue #619
- DocPad will now run the local installation if it exists (avoid this by using the
--globalflag)- Thanks to Eduan Lavaque and flamingm0e for issue #620
- Added the ability to uninstall plugins via
docpad uninstall <pluginName> - Updated dependencies
- Fixed validation of DocPad sites containing the powered by info
- Thanks to drguildo and Eduan Lavaque for issue #618
- Upgraded from commander v1.3 to v2 (removes commander prompts)
- We now use promptly for prompts
- Updated dependencies
- Fixed
File::deleteSource - Plugin tester will now try to init the plugin test directory if there are tests defined (useful for plugins which tests start from scratch)
- Updated dependencies
loadFilesstep is now properly reported in the progress bar- Thanks to Bruno Heridet for pull request #498
- DocPad will now shutdown and destroy itself more thoroughly
- Thanks to Ashton Williams for issue #595
- Added the event
docpadDestroyfor plugins that are doing anything long-running so they can destroy themselves thoroughly too
- Fixed outputting filenames without an extension
- Thanks to Geert-Jan Brits for issue #584
- Moved
regenerateEverytimer intogeneraterather thansetConfigto avoid action stacking - DocPad will now warn you when your project's local DocPad version does not match the global version
- Added
FileModel::deleteSource - Added support for specifying inline content within the styles block
- Fixed
DocPad::parseFileDirectory
- Fixed
ReferenceError: result is not defined(bug since v6.46.4)- Thanks to Anup Shinde for issue #573
- Fixes
- Fixed virtual documents firing duplicated events
- Plugins should now use
DocPad::cloneModel(model)instead ofmodel.clone()as the latter can't bind events correctly
- Plugins should now use
- Fixed
Object #<Model> has no method 'setDefaults'error (bug since v6.46.3)- Moved
FileModel::setDefaultsback intoBase::setDefaults - Thanks to Jeff Barczewski for bevry/docpad-documentation#40
- Moved
- Fixed the 500 middleware not working
- Fixed virtual documents firing duplicated events
- Changes
- The
documentscollection is now defined byrender:true, write:truerather than being paths andisDocument:truebased - The
filescollection is now defined byrender:false, write:truerather than being paths andisFile:truebased - The
htmlcollection now checks forwrite:trueinstead ofisDocument:trueorisFile:true - The
stylesheetcollection now checks forwrite:trueinstead ofisDocument:trueorisFile:true
- The
- Additions
- Added ability to do
getCollection('database')to get the global database - Added naming to collections to easily identify which collection we are in when debugging
- Added
renderalias for documents directory - Added
staticalias for files directory - Added logging for event emits
- Re-added
DocPad::parseDocumentDirectoryandparseFileDirectory(removed from v6.46.0) which wraps around the new ways of doing things - Added
DocPad::createModel(attrs,opts)and updatedDocPad::createDocumentandDocPad::createFileto use it - Added
DocPad::ensureModel(attrs,opts)and updatedDocPad::ensureDocument,DocPad::ensurefile, andDocPad::ensureFileOrDocumentto use it - Added
DocPad::attachModelEvents(model)to attach the required docpad events to a model
- Added ability to do
- Moved
Base::setDefaultstoFileModel::setDefaults - Removed superfluous loading logging messages
- Thanks to Bruno Heridet for issue #316
- The attributes
parser,header,body, andcontentare now set correctly tonullinstead ofundefinedif there is no data - Correctly set meta attributes when also setting default attributes (bug since v6.42.2)
- Added support for
outPath,outDirPathandrootOutDirPathto be null - Added unit tests for virtual document loading
- Fixed
removeWhitespacetester option default - Added
contentRemoveRegextester option - Fixed debug log lines always being
DocPad.log(bug since always)
- Fixed regenerations not regenerating referencing documents (bug since v6.46.0)
- Closes issue #559
- Fixed documents not including the default attributes of files (bug since always)
- Corrected naming of
releativeOutBasetorelativeOutBaseon file model defaults (introduced in v6.45.0)
- Added
populateCollectionsBeforeevent
- Awesomeness for everyone
- Added support for creating brand new virtual documents
- File
datawill now just set thebuffer- Removed
getDataandsetDataon models
- Removed
- Can now
docpad installmultiple plugins at once - Plugin loading will now validate the
peerDependenciesrequirements along with the oldengines docpad initwill now initialise to the complete docpad version and npm v1.3- You can now tell a file to update it's source file by setting
writeSource: truein it's meta data
- Awesomeness for developers
- We now require all plugins to conform to the v2 for DocPad v6 standard, otherwise they will be skipped
- This is to ensure compatibility with
docpad updateanddocpad install <plugin>which are the new standards for installing plugins
- This is to ensure compatibility with
parseDirectorywill no longer:- load files, this is now handled by the generate process instead
- add files to the database, this can be done via the completion callback or via passing over the collection the files should be added to:
parseDirectory({collection:docpad.getDatabase()})
- Removed
parseDocumentDirectoryuseparseDirectory({createFunction:docpad.createDocument})instead - Removed
parseFileDirectoryuseparseDirectory({createFunction:docpad.createFile})instead Document::writeRenderedremoved asFile::writewill now write the output content- Added
File::writesource - Added
PluginTester::getConfig()andPluginTester::getPlugin()
- We now require all plugins to conform to the v2 for DocPad v6 standard, otherwise they will be skipped
- Updated dependencies
- Fix
safeps is not definederror- Thanks to Carlos Rodriguez for issue #558
- New
docpad updatecommand to ensure that your local installations of DocPad and its plugins are up to date with their latest compatible version docpad install [plugin]command now installs the latest compatible version- Added NodeFly support when using the
--profileflag
- Model Improvements
- Way better support for virtual documents (files that do not have a physical path)
- Cleaned up and fortified the normalization and contextualize procedures
- At least one of these file attributes must be specified:
filename,relativePath,fullPathrelativePathif not set will default tofullPathorfilenamefilenameif not set will default to the filename offullPathorrelativePathfullPathwill not default to anything, as it is now optional (providing better support for virtual documents)
- The following file attributes are auto set but can be over-ridden by custom meta data:
date,name,slug,url,contentType,outContentType,outFilename,outExtension,outPath - The following file attributes are forcefully auto set:
extensions,extension,basename,outBasename,relativeOutPath,relativeDirPath,relativeOutDirPath,relativeBase,relativeOutBase,outDirPath - Added these new file attributes:
outBasename,relativeOutBase,fullDirPath - Updated a lot of log messages to support virtual documents
bufferis now correctly set as a File optionFile::setMeta(attrs)can now accept meta backbone models instead of just javascript objects- File and Document methods now use extract-opts for their arguments just like DocPad already does
- Removed the incorrect dangling file attributes:
pathanddirPath - Added new
FileModel::clonemethod for making a clone of the file, attributes, opts, events and all will be cloned
- Core Improvements
- Added
getFileById(id, opts={})template helper and docpad class method - Plugins can now alter the load, contextualize, render, and write collections
- Added a new
lib/utilfile for containing misc functions - Added
DocPad::destroy()method for shutting down the server and whatnot- Currently only shutdowns the server, we still need to add the rest of the things
- Added
- Testing Improvements
- RendererTester is now more helpful when comparing differences between outputs
- DocPad tests now use the new docpad destroy method that allows graceful shutdown rather than the previous ungraceful
process.exit(0)- Still needs to be applied to plugin tests
- Fixed
locale is not definederror when runningdocpad initon an existing website
- Fixed
docpad initconfig error
- Huge improvements to the skeleton install process
- Install process is much more reliable
- Skeleton dependencies will now install correctly if
node_modulesalready exists - Missing module errors when doing an initial clone of a skeleton should now be fixed
- Removed the unused and non-working
-s, --skeletonoption
- Activities that wait on remote activity will now output a please wait message
- You can now install plugins via the
docpad install [pluginName]command- Thanks to Jarvis Ao Ieong for issue #539
- Installing dependencies via the
docpad installcommand now works again - The
-f, --forceflag now works as expected (enabling the npm--forceflag) - Fixed an issue with arrays not being dereferenced correctly in configuration
- This fixes initial run issues with skeletons that have custom file structures
- Added
--offlineflag that will help docpad run without an internet connection - Added an interval timer to load, contextualize, render, and write actions to determine what files we are waiting on
- Dependency upgrades
- Swapped out synchronous file system calls for asynchronous ones
- Closes issue #538
- Fixed DocPad version number undefined in X-Powered-By response header
- Added the ability to turn off the X-Powered-By meta header by setting the
poweredByDocPadtofalsein your configuration
- Fixed backslash and slash inconsistencies on windows in regards to searching
- Thanks to Hamish for issue #533
- Fixed backslash and slash inconsistencies on windows in regards to urls
- Thanks to jhuntdog for issue #518
docpad renderwill no longer output warning levels
- Better lazy loading of modules
- Updated dependencies
- Made debugging, tracing, and profiling easier
- Added
docpad-debugfor easy debugging - Added
docpad-tracefor easy tracing - Added
--profilefor easy profiling
- Added
- Removed excessive dirname usage
- Updated dependencies
- Abstracted out the file fetching in
DocPad::serverMiddlewareRouterintoDocPad::getFileByRoute(url, next)for others to use in their custom routes - Updated dependencies
- Fix compilation issue with CoffeeScript v1.6.3
- Updated dependencies
- Added
docpad initaction to initialize your directory with an empty docpad project
- Added scripts.start property to no-skeleton's package.json file
- Plugin tester file is now optional when specifying something like
testerClass: 'RendererTester'inside your plugin test file- Closes issue #487
enableUnlistedPluginsis now set totruewhen running plugin tests (it wasfalsebefore)- This allows us to remove the need for the plugin tester file for most situations
- You will now be warned if your custom collection is invalid
- Child collections will now be of the correct class type
- Fixed
TypeError: Object has no method 'unbindEvents'
- Rewrote the error-reporting, analytics, newsletter, and identification handling
- Fixed a bug with the plugin version not being set on the plugin instance correctly
- We now respect plugin priorities again
- Thanks to Neil Taylor for pull request #511
- Set plugin priorities by
priority: 500or whatever in your plugin class - Set event specific priorities by
eventNamePriority: 500or whatever in your plugin class
- Updated dependencies
- We now support
docpad runon empty directories when offline- Before it would crash because it could not load the exchange data, now it will continue anyway
- Removed
cli-colordependency - Progress bar will now be destroyed when a notice or higher importance message is logged
- Fixed
ReferenceError: docpad is not defined
- Now uses envfile for
.envfile parsing - Fixed
TypeError: Cannot call method 'get' of undefinederror when using minicms plugin- Closes issue #501 reported by rleite
- We now load the exchange file based on which DocPad version we are running
- Updated dependencies
- Caterpillar Human v3.1 from v3.0
- Now uses Caterpillar v2
- We now write a
docpad-debug.logfile when running with the-dflag, submit this when you file a bug report :) - Fixed colors not showing on custom Terminal color schemes
- Fixed a double progress bar issue when a log message occurs when the progress bar is being written
- Removed
setLogger()instead you should dogetLogger()and pipe the results to where you need - Added
getLoggers()to fetch all the different logger streams we are using, generally there are:loggerthe stream we write log messages toconsolethe stream that is outputted to stdoutdebugthe stream that is outputted to the debug log file
X-Powered-Bynow also includes the DocPad version number
- Progress bars now obey the
promptsconfiguration option instead of v6.31.2 environment hack
- Fixed "ReferenceError: existingModel is not defined" when you have outPath conflicts
- Moved progress bar code into bevry/progressbar
- Fixes issues with progress bars on Ubuntu and Windows
- Do not show progress bars on production environments
- Fixed cannot get
lengthof undefined error - Added progress bar (instead of snores) for during generation when using the default log level (
6)
- DocPad will now warn you when you have files of the same outPath
- File and Document IDs will now always be their
cid(before they use to be their relativePath on occasion) - Fuzzy searching no longer searches for the id
- Server is now able to serve cached pages while a non-initial generation is occurring
- We no longer replace tabs with 4 spaces for the content of files and documents (we still do it for YAML meta data headers on documents)
- This means if you're a plugin developer, you may need to update your plugin's test's
out-expectedfolder accordingly- If this is too difficult, we've added a
removeWhitespaceconfig option for your plugin tester, set it totrue, see here for usage
- If this is too difficult, we've added a
- This means if you're a plugin developer, you may need to update your plugin's test's
- Change events will now fire when adding a url to a file
- URL cache index for serving files is now generated via change events, rather than after generation
- The no skeleton option will now create a
node_modulesdirectory, andpackage.jsonanddocpad.coffeefiles
- Testing of plugins now works when the plugin directory is the full plugin name
- Thanks to Mark Groves for issue #485
- Updated dependencies
- Allow for empty
datawhen injecting files into the database- Thanks to Richard A for pull request #454
- Fixed "No Skeleton" option not working (bug introduced in v6.30.0)
- Thanks to Adrian Olaru for pull request #475
- Updated dependencies
- Progress on issue #474
balUtil,chai,expect,assert,requestare no longer exposed to plugin testers, you'll need to include them yourself from now on- Updated dependencies
- Progress on issue #474
- DocPad will now set permissions based on the process's ability
- Thanks to Avi Deitcher, Stephan Lough for issue #165
- Updated dependencies
- Removed native prototype extensions
- Thanks to David Baird for issue #441
- If you were using
toShortDateString, then we'd recommend this gist instead - If you were using
toISODateString, just replace it withtoISOString
- Engine requirements are now:
- node >=0.8
- npm >=1.2
- Iconv is now a lazy loaded dependency
- Thanks to jhuntdog for issue #468
- Added
regenerateDelayconfiguration option- Thanks to Homme Zwaagstra for pull request #426
- Fixes
TypeError: Object #<Object> has no method 'removeListener'- Thanks to Steven Lindberg for issue #462
- Can now customise the
watchOptionsthat are used to construct the watchr instances we create - Updated dependencies
- We now gather statistics on the node version and platform you are using to better understand where issues are coming from
- Updated dev dependencies
- coffee-script ~1.4.0 to ~1.6.1
- request ~2.14.0 to ~2.16.2
- Node v0.10.0 support - fixes the "Arguments to path.join must be strings" errors
- Thanks to Merrick Christensen for issue #455
- The requirement of "plugins must have their own
package.jsonfile withversionandmaindefined within them" is now enforced - Updated dependencies
- Database is now persistent
- We now destroy unused collections
- Fixed regression from v6.24.1 that caused new installs or very old upgrades to get stuck in the TOS section
- Typo fixes
- Fixes
getMixpanelInstance()always re-creating the mixpanel instance instead of just doing it once - Fixes
DocPad::getBlocks - Thanks to Richard A for pull request #450
- Fixes
- Fixed mixpanel country and language always being au and en
- Updated dependencies
- bal-util ~1.16.3 to ~1.16.10
- Configuration changes and improvements
- Can now load the configuration before the console interface is setup, allowing us to have plugins that extend the console interface
- Currently explicit commands only
- Configuration can now load multiple times safely
- Plugins now have
initialConfig,instanceConfig, and asetConfig(instanceConfig=null)helper and their configuration will be reloaded viasetConfigeach time the docpad configuration is reloaded- NOTE: This means no modifying
configdirectly in your constructor as the changes won't persist, instead modify them via thesetConfigcall after callingsuper- See the partials plugin for an example of this
- NOTE: This means no modifying
- Thanks to Olivier Bazoud for issue #63 and thanks to Avi Deitcher, Sergey Lukin, Zeno Rocha for issue #39
- Can now load the configuration before the console interface is setup, allowing us to have plugins that extend the console interface
- Added
docpad action <actions>command line action - When passing arrays to blocks we now clone the array to avoid modifying the argument
- DocPad can now handle foreign encodings when you set
detectEncoding: truein the docpad configuration- Thanks to Yellow Dragon for issue #411
- Better port assignment to testers - changeset
- We now identify anonymous users (while respecting their anonymity) - changeset
- Closes #430
- Updated dependencies
- watchr ~2.3.4 to ~2.3.7
- Works better for projects that have a large amount of files
- watchr ~2.3.4 to ~2.3.7
- We now completely ignore growl failures
- We now alert the user of watch failures but still ignore them overall (as to not bring down the entire app)
- Updated dependencies
- Swapped out underscore dependency for lodash
- Underscore is no longer provided to testers
File::getMetanow aliases toFile.getMeta().getif arguments have been supplied- No longer does deep clones on template data per file render (just shallow clone now)
- Fixed a bug that keeps
existsattribute onFilealwaystrue- Thanks to Stefan for pull request #409
- Updated dependencies
- Fixed port not defaulting correctly on the
docpad-serverexecutable since v6.21.5- Thanks to man4u for issue #407
- Updated dependencies
- bal-util ~1.16.0 to ~1.16.1
- Better debugging around server starting
- Supports Node v0.9
- Added
renderSingleExtensionsoption- Note: currently this will render
src/documents/script.coffeefrom CoffeeScript to JavaScript as intended, HOWEVER the outfile will beout/script.coffeeinstead of the expectedout/script.js. We will likely have to do an extension mapping for single extensions.
- Note: currently this will render
- Added experimental
docpad-compileexecutable - Updated dependencies
- bal-util ~1.15.4 to ~1.16.0
- Fixed incorrect meta data parsing for certain files
- Thanks to Jose Quesada and Stefan for issue #394
- Scripts and styles blocks now support an
attrsoption string- Thanks to Alex for pull request #397
- Thanks to edzillion for issue #400
- Fixed ignored files sometimes triggering reloads
- Added
ignorePaths,ignoreHiddenFilesoptions - Added
DocPad::isIgnoredPath,DocPad::scandir,DocPad::watchdirhelpers
- Fixed
Base::setDefaultsandFile::setMetaDefaultsalways forcing defaults- Thanks to Stefan for pull request #396
- Added support for running multiple plugin tests for the same plugin
- Closes issue #393
- Cleanup focused around loading, parsing, and writing of files and documents
- Added
DocPad::flowDocumentDocPad::loadDocumentexistsattribute onFilemodel
- Fixed
Document::writeSource
- Fixed
File::writeSource- Thanks to ashnur for pull request #381
- Better watch handling
- Updated dependencies
- watchr ~2.2.1 to 2.3.x
- Renamed
ignorePatternsconfiguration option toignoreCommonPatternsand added newignoreCustomPatternsconfiguration option - Updated dependencies
- Updated optional dependencies
- mixpanel 0.0.9 to 0.0.10
- Updated dev dependencies
- chai 1.3.x to 1.4.x
- Added
regeneratePathsconfiguration option - Include now returns expected results if the content hasn't been rendered yet
- Closes issue #378
- Updated QueryEngine v1.4.x to v1.5.x
- Backbone dependency now moved to our dependencies from QueryEngine's. Version set explicitly to v0.9.9.
- If you have any plugins or whatever that used the
myCollection.getByCidfunction, change that call tomyCollection.get
- If you have any plugins or whatever that used the
- Improved help URLs
- Fixed an issue introduced in v6.17.0 that prevented files from reloading under certain circumstances
- Thanks to Vladislav Botvin for issue #370 and pull request #371
watchandserveractions now perform an initial generation- Thanks to Khalid Jebbari, Vladislav Botvin for issue #369, issue #368, issue #366
- Updated misc internals to use the new
File::getOutContentcall
- Cleaned up the way we handle buffers, data, and meta data - more efficient and simpler api
- Updated
File::getMetato create meta if it doesn't exist yet
- Removed
Document::initializedidn't do anythingDocument::getMetadidn't do anythingFile::readFilemerged intoFile::parseFile::parseDatarenamed toFile::parseand cleaned significantly
- Added
Base::setDefaultsto update attributes that haven't been setFile::setMetato update the meta more easily thanFile.getMeta().setFile::setMetaDefaultsto update the meta attributes that haven't been setFile::getContentto get the content or bufferFile::getOutContentto get the rendered content, or content, or bufferFile::getStatto get the statFile::setBufferto set the bufferFile::getBufferto get the buffer
- The amount of render passes is now customisable via the
renderPassesconfiguration option, defaults to1- Increment this value depending on how many levels of cross-document references you have (e.g. 2 passes for C includes B, B includes A)
- The render pass functionality has been changed to render all documents that don't reference anything else first, then for each additional render pass, render documents that do reference others
- Previously it would render both types of documents in the one batch, which resulted in hit and miss results
- Doing this, we now safely have the default
renderPassesvalue set to1which has the same effect as the traditional2render pass - Refer to issue #359 for more information
- Nodejitsu Support
- Added
DocPad::getFileByUrl(url)and updated the middleware router to use it- Big performance gain on request response time
reportErrorsandreportStatisticsare nowfalseiftestis included in theprocess.argv- Closes issue #354
- Fixed the
includetemplate helper DocPad::getFileAtPathnow does fuzzy findingFilesCollection::fuzzyFindOnenow also fuzzy matches against the url and acceptssortingandpagingarguments
- Reduced the extension not rendering error to a warning
- Fixed up growl notifications
- Added Terms of Service and Privacy Policy confirmation
- Added statistic tracking so we can better understand usage allowing us to improve DocPad is much greater ways
- Added automatic locale detection for OSX
- Improved error reporting
- Will now error if you try to run an action that doesn't exist (instead of defaulting to the
runaction instead) - Updated dependencies
- Added dependencies
- Mixpanel 0.0.9
- Moved dependencies to dev dependencies
- Fixed update check, been broken since v6.7.3
- Updated bal-util dependency from 1.13.13 to 1.14.x
- When creating new documents or files, if it is inside an unknown path we will now default to creating a document instead of a file
- We now send growl notifications when errors occur
- Thanks to Luke Hagan for pull request #346, issue #343
- We now error and provide suggestions when an extension transform doesn't do anything
- Thanks to Farid Neshat, Elias Dawson, Steve Trevathan for issue #192
- Watching stability has been improved significantly
- Thanks to ashnur for issue #283
- Parser headers that don't include spacing now work again (e.g.
---csoninstead of--- cson)- Thanks to bobobo1618 for issue #341
- Removed default comparator on
FilesCollectiondue to performance improvement it provides- Thanks to Bruno Héridet for issue #330
- Added
Document::parseFileDirectory(opts,next)Document::parseDocumentDirectory(opts,next)FilesCollection::fuzzyFindOne(data)
- Changes made to help get the docpad server up and running as soon as possible:
serveraction is now run beforegenerateaction- if a request is made while a generation is occurring, the request will be put on hold until the generation completes
- We now pass the option
resetto thegenerateBeforeevent- Lets you know if the generation is a complete generation (
resetistrue) or a differential generation (resetisfalse)
- Lets you know if the generation is a complete generation (
- Updated QueryEngine dependency from 1.3.x to 1.4.x
- Should see speed improvements
- Added
docsdirectory to.npmignore
- Updated QueryEngine dependency from 1.2.3 to 1.3.x
- Should see better memory usage and speed improvements
- Now tells you how many files we have when doing a complete render
- Added
reloadPathsconfiguration option- When a change occurs in one of the reload paths then we will reload docpad
- Added
getBlocksandsetBlocks - Added
getCollectionsandsetCollections - Will now output how long the generation took
- Updated dependencies
- CoffeeScript 1.3.x to 1.4.x
- CSON 1.2.x to 1.4.x
- Joe 1.0.x to 1.1.x
- Underscore 1.3.x to 1.4.x
- Chai 1.1.x to 1.3.x
- Removed ability to require uncompiled plugins
- This is due to the CoffeeScript 1.4.x from 1.3.x upgrade
skeletonNonexistantnow tells us the path it checked
- Added
getEnvironmentandgetEnvironmentstemplate helpers
- Fixed growl generating notification from saying
generatedinstead ofgenerating - Added
ignorePatternsoption- Thanks toBruno Héridet for issue #193, pull request #326
- Updated the document meta data extraction regex - It will now treat data that is wrapped in anything that repeats 3 or more times, as meta data allowing you to use whatever is appropriate for the markup you are currently in (before we only supported
---and###)
- Fixed
--portCLI option not working (and possibly others) - Fixed
docpad skeletonblocking instead of ending- Thanks to Bruno Héridet for issue #225
- Improved localisation
- Thanks to Bruno Héridet for pull request #325
- Added support for
.envfiles- If a
.envfile is present in your website path, we will add its key values toprocess.env - More information on
.envfiles here
- If a
- Improved localisation
- Thanks to Bruno Héridet for pull request #323
- Removed unused model requirement inside document model file
- Thanks to Bruno Héridet for pull request #318
PORTenvironment variable now comes before infrastructure specific port variables- Can now do
docpad-server --action generate,server,watch --port 8080
- Fixed logging when a fatal error occurs during initialisation
- We now do warnings when plugins do invalid naming conventions
- Closes #313
- Help by Eugene Mirotin
- We now display the plugin versions in the plugin listing information when debugging
- Help by ashnur
- More localization progress
- Fixed custom middleware (via the
serverExtendevent) being loaded too late (after the express router middleware)
- Can now use the
urlproperty in meta data to specify a custom URL to use - Collection creation functions in the DocPad Configuration Files now scope to the DocPad Instance
- Fixed the 400 and 500 middlewares
- Server changes:
- Updated Express.js from v2.5 to v3.0
- If you're doing custom routing, you'll want to check the Express.js Upgrade Guide
- There are now two server objects:
serverExpressandserverHttp- get them usingdocpadInstance.getServer(true), set them usingdocpad.setServer({serverExpress,serverHttp})-serverin events, anddocpadInstance.getServer()return theserverExpressobject for backwards compatibility (however things like socket.io require theserverHttpobject) - Closes #311, #308, #272, #274
- Help by dave8401 and Ben Harris
- Abstracted out the different middlewares to
serverMiddlewareHeader,serverMiddlewareRouter,serverMiddleware404, andserverMiddleware500 - Added the following options to the
serveractions:serverExpressfor a custom express.js serverserverHttpfor a custom http servermiddlewareStandardset it tofalsefor us to not use any of the standard middleware (body parse, method override, express router)middlewareBodyParserset it tofalsefor us to not add thebodyParsermiddlewaremiddlewareMethodOverrideset it tofalsefor us to not add themethodOverridemiddlewaremiddlewareExpressRouterset it tofalsefor us to not add the Express.jsroutermiddlewaremiddleware404set it tofalsefor us to not add our404middlewaremiddleware500set it tofalsefor us to not add our500middleware
- Example API usage can be found here
- Updated Express.js from v2.5 to v3.0
- Added
standaloneattribute to files (defaults tofalse)- If you set to
true, changes to the file will only cause re-rendering of that file alone
- If you set to
- Added a progress indicator during generation
- Closes #247
- Help by Bruno Héridet
- Fixed watching setup not completing under some conditions
- Bumped watchr minimum version to v2.1.5
- Added built-in support for AppFog and CloudFoundry ports
- Further improved file text/binary detection
- Further improved file encoding detection
- Closes #266: Images are broken
- Better file encoding detection
- Fixed
dateandnamealways being their automatic values
- Added
docpad-debugexecutable for easier debugging - Will now ask if you would like to subscribe to our newsletter when running on the development environment
- Beginnings of localisation
- Fixed "cannot get length of undefined" intermittent error
- Due to an incorrect variable name inside
DocPad::ensureDocumentOrFile
- Due to an incorrect variable name inside
- Added
regenerateEveryconfiguration option
- IMPORTANT: Renamed
extensionRenderedtooutExtension,filenameRenderedtooutFilename, andcontentTypeRenderedtooutContentTypeand moved them from the Document model to the File model - The
serverExtendevent will now also emit theexpressdependency if used - No longer attempts to install plugins dependencies every time, this is outside the scope of DocPad and in the standard use cases already handled via npm
- No longer accepts
npmPath,gitPath, andnodePathas configuration options, instead these should be environment variables atNPM_PATH,GIT_PATH, andNODE_PATHrespectively (without the underscore is also acceptable) - Eliminated ambiguity with
renderSingleExtensions- if
trueit will rendermarkdown,.mdandexample.md - if
'auto'it will rendermarkdownbut not.mdandexample.md autois now used on thedocpad rendercommand
- if
- Can now specify a custom configuration file vis the command line using
-c, --config <configPath> - Can now specify a custom outPath via the command line using
-o, --out <outPath> - Can now set template data via
req.templateData - Can now customise the action that the
docpad-serverexecutable performs by setting theDOCPAD_SERVER_ACTIONenvironment variable - Fixed
Document::writeSource - Fixed
require('docpad').createInstance(was accidentally dropped in v6.2.0) - Fixed
no readmenpm warning- Removed markdown files from
.npmignoreas they are now required for the new npm website listing
- Removed markdown files from
- Fixed the regeneration not picking up changes when modifying a referenced stylesheet
- Added a new
stylesheetcollection that contains any stylesheet file (including pre-processors) and sets theirreferenceOthersproperty totrue
- Added a new
- Fixed
contextualizeBeforeandcontextualizeAfterevents not firing- Thanks to Bruno Héridet for pull request #277
- Fixed
contentTypebeing looked up twice- Thanks to Nick Crohn for pull request #273
- Added new
sourceattribute to the file model, as thecontentattribute on the document model is actually thebodynot the original content like it is in the file model
- We now support
404 Not Foundand500 Internal Server Errorerror pages thanks to Nick Crohn for pull request #251 - Fixed #269 where the
docpad rendercommand wouldn't work - Fixed #268 where files which names start with a
.from having a.appended to their output filename
- Fixed binary file output
- Added binary files to the test suite so this won't happen again
- Was due to the dereference on the new clear introduced in v6.3.0
- As such, we now store the
dataattribute for files outside of the attributes, usegetDataandsetData(data)now instead ofget('data')andset({data:data})
- As such, we now store the
- Fixed install action
- Fixed
extendCollectionsbeing called before the plugins have loaded when using the CLI
- Added support for multiple environments
- Top-level configuration assumed to reflect the production environment, other environments will extend from it
- This is because getting a production environment configuration inside your development environment is fine, however getting a development environment configuration inside your production environment is catastrophic - as such, having the top-level configuration reflect the production environment handles this assumption correctly
- Added environment configuration support to plugins and their configuration
- Removed
package.json > docpad > pluginconfiguration mode for a plugin'spackage.json, they should use theconfigproperty in their class instead - Added
isEnabled()to the plugin class, this reflects theenabledproperty in the plugin configuration, if it is false, then no events are executed for that plugin - Killed the
docpad cliaction, no one used it and introduced a lot of complexity to the codebase - Added
populateCollectionsevent, use this to insert things into our collections and blocks - Added
docpadLoadedevent which fires whenever our configuration is re-loaded - Added support for overriding the
extensionattribute via your document's meta data - Added support for the
renderSingleExtensionsattribute in documents- Closes issue #772
- Fixed
cleanaction from not behaving as expected- Had the wrong indexOf indice value in the check
- Fixed default attributes not being kept inside document and file attributes when cleared
- Turns out Backbone's
Mode::clear()wipes everything, rather than reset to the default attributes and values
- Turns out Backbone's
- Dropped node v0.4 support
- Minimum required version is now 0.6
- Dropped
npmdependency - Configuration merging now deep extends plain javascript objects
- Added environment specific configuration support
- By default we use
process.env.NODE_ENVfor the environment, falling back todevelopment - Specify your environment specific configuration in
environments[env] - By default, our production environment sets
maxAgeto one day, andcheckVersionto false - Use
getEnvironmentto get the current environment
- By default we use
- Added new
extendCollectionsevent - Added check during clean action to ensure we don't remove outPath if it is higher than our rootPath
- Added
docpad-serverbinary to shortcut heroku deployment - Scripts collection now supports adding plaintext javascript
consoleSetupoptions are nowconsoleInterfaceandcommanderinstead ofinterfaceandprogram- DocPad's main file is now
out/main.coffeeand the exportedrequireis now limited to files in theoutdirectory (not higher)
- Fixed
extendTemplateDataevent firing before our plugins have finished loading
- Fixed
DocPad::getBlock
- Added
htmlcollection - Dependency updates
- chai from v1.0 to v1.1
- End user changes
- Added support for using no skeleton on empty directory
- Action completion callback will now correctly return all arguments instead of just the error argument
- Filename argument on command line is now optional, if specified it now supports single extension values, e.g.
markdowninstead offile.html.md - When using CoffeeScript instead of YAML for meta data headers, the CoffeeScript will now be sandboxed
- If you are wanting to get stuff outside the sandbox write a
docpad.coffeeconfiguration file
- If you are wanting to get stuff outside the sandbox write a
- Document and File model changes
- Now work fine without any path specified
rendersplit intorenderExtensions,renderDocumentandrenderLayoutrenderExtensionsnow supports the optionrenderSingleExtensionswhen specified, will prepend the extensionnull, allowing supported plugins to render single extensionsrendernow supports the optionactionswhich is an array of actions to perform- we now do not clear the
contentRendered,contentRenderedWithoutLayouts, andrenderedproperties between render passes
- DocPad prototype changes
- New Events
extendTemplateData, opts:templateData,extend(objs...)
- Attached Classes
Base,Model,Collection,View,QueryCollectionFileModel,DocumentModelFilesCollection,ElementsCollection,MetaCollection,ScriptsCollection,StylesCollectionPluginLoader,BasePlugin
- New Collection Helpers
getFiles(query,sorting,paging)getFile(query,sorting,paging)getFilesAtPath(path,sorting,paging)getFileAtPath(path,sorting,paging)
- New Render Helpers
loadAndRenderDocument(document,opts,next)renderDocument(document,opts,next)renderPath(path,opts,next)renderData(data,opts,next)renderText(text,opts,next)
- New Template Data Helpers
referencesOthers(flag)getDocument()getPath(path,parentPath)getFiles(query,sorting,paging)getFile(query,sorting,paging)getFilesAtPath(path,sorting,paging)getFileAtPath(path,sorting,paging)
- New Events
- Added the following to the export
Backbone,queryEngine
- Dependency updates
- Configuration variables
documentPaths,filesPaths, andlayoutsPathsare now relative to thesrcPathinstead of therootPathpluginsPathsis still relative to therootPath
- Added
getFileModel,getFileUrl,getFiletemplate helpers
- More robust node and git path handling
- Dependency updates
- bal-util from v1.9 to v1.10
- We now output that we are actually installing the skeleton, rather than just doing nothing
- We now also always output the skeleton clone and installation progress to the user
- Skeletons are now a backbone collection
- Fixed CLI on certain setups
- Many minor fixes and improvements
- Available DocPad events are now exposed through
docpadInstance.getEvents() - DocPad configuration is now exposed through
docpadInstance.getConfig() - Removed
DocPad::getActionArgsin favor ofbalUtil.extractOptsAndCallback - Configuration events now have a context that persists and do not pile up if configuration is reloaded
- DocPad constructor now returns
erranddocpadInstanceto the completion callback if it exists - Fixed a problem with grouped actions not completing under some circumstances
- Will now watch configuration files for changes, if a change is detected, regenerate everything
- Cleaned up the server action a bit
- Added a new
serverExtendevent so listeners can now extend the server before the docpad routes are applied - Dependency updates
- watchr from v2.0 to v2.1
- Configuration changes
- DocPad now checks the following paths for a configuration file
docpad.js,docpad.coffee,docpad.json,docpad.cson, and will go with whichever one it finds first- If you use
coffeeorjsextensions, remember to prefix your file withmodule.exports =
- If you use
- Fixed instance configuration not always coming first
- Removed
configPathconfiguration option. Use the array basedconfigPathsinstead. rootPathandconfigPathswill now be properly respected if specified in yourpackage.jsonfile under thedocpadproperty- Configuration files can now bind event handlers using the
eventshash
- DocPad now checks the following paths for a configuration file
- Event changes
- Completion callbacks are now optional for event listeners, if omitted event listener will be treated as synchronous
- Added new
docpadReadyevent that fires once docpad has finished initializing and loading its configuration, will provide the opts{docpad}wheredocpadis the docpad instance
- Server changes
- If a document has multiple urls, and it is accessed on the non primary url, we will 301 (permanent) redirect to the primary url
- Dependency updates
- When watching files, and you modify a layout, docpad will now re-render anything using that layout - closes #242
- Greatly simplified the event architecture
- We now inherit from the simpler
balUtil.EventEmitterEnhancedinstead ofbalUtil.EventSystem, and have moved queue code intobalUtil.GroupasdocpadInstance.getRunner() - Actions when called directly do not queue, they only queue when called through
docpadInstance.action
- We now inherit from the simpler
docpadinstance.loadConfigurationis now an action calledload- Fixed the run action not completing due to a missing callback
- Updated QueryEngine from version 1.1 to 1.2
- Fixed watch error when deleting files, or changing a directory
- Fixed skeleton action
- Fixed
serveraction when used in combination with a custom server
- Now fetches the DocPad v6 exchange file
- Fixed plugin generation tests
- Breaking changes that may affect you
- Removed
documentsPath,filesPath,layoutsPathconfiguration options for their array based alternativesdocumentsPaths,filesPaths,layoutsPaths - Removed
requirefromtemplateDataas it needs to be specified in your project otherwise it has the wrong paths - Removed
database,collections,blocksfromtemplateDatafor their helper based alternativesgetDatabase(),getCollection('collectionName'),getBlock('blockName') - Removed
String::startsWith,String::finishesWith,Array::hasCount,Array::hasas we never used them - Removed
DocPad::documentsandtemplateData.documents, now usegetCollection('documents')
- Removed
- New features
- Differential rendering
- Extendable CLI
- Template helpers
- Other changes
- Better error handling
- Moved to Joe for unit testing
- Fixed layout selection when two layout's share similar names - Closes #227
- Upgraded chai dev dependency from 0.5.x to 1.0.x
- Fixed a dereferencing issue
- Plugin testers will now run the
installandcleanactions when creating the DocPad instance
- DocPad will no longer try and use a skeleton inside a non-empty directory
- DocPad will now only include the CoffeeScript runtime if needed (for loading CoffeeScript plugins)
- Fixed #208 - Multiple file extensions being trimmed
- Fixed #205 - Name collisions are causing not all files to be copied
- Changed file
idto default to therelativePathinstead of therelativeBase - Finding layouts now uses
id: $startsWith: layoutIdinstead ofid: layoutId
- Fixed a complication that prevents
src/publicfrom being written toout- Added automated regression tests to ensure this will never happen again
- Added
documentsPaths,filesPaths, andlayoutsPathsconfiguration variables - Simplified model code
- Cleaned up some async code
- We now pre-compile our CoffeeScript
- Added the ability to specify a
docpad.csonconfiguration file inside your website- This file will also be watched for changes, and if a change is made, we'll reload it and regenerate :)
- Database/Collections have been cleaned up
- files, layouts and documents are all added to the database
- documents and layouts are represented by the
Documentmodel which extends theFilemodel - files are represented by the
Filemodel - documents are accessible via the
collections.documentswhich is a live child collection of database - files are accessible via the
collections.fileswhich is a live child collection of database - layouts are accessible via the
collections.layoutswhich is a live child collection of database
- You can create your own live child collections by specifying them in your configuration file, e.g. add this to your
docpad.csonfile:# Collections collections: pages: (database) -> database.findAll(pageOrder: $exists: true) posts: (database) -> database.findAll(tags: $has: 'post')
- Templates now have access to a new function called
include. It will include the renderedContent (or if unavailable to content) of the file. In eco, you would use it like this:<%- @include('filename.ext1.ext2.ext3') %> - Blocks are now Collections too! You can call
.addon them, and use.toHTML()to grab them as HTML (.joinwill do the same thing for b/c) - This should be a completely backwards compatible release, let us know if you any issues on the
- Fixed some UTF8 encoded files from being detected as binary
- Fixed documents with no extension being outputted with an undefined extension
- Fixed EventEmitter warning
- Binary files can now be placed within the
src/documentsdirectory - Removed eyes devDependency
- Models now use CoffeeScript's class extend, instead of Backbone's extend
- Added
.npmignorefile - Added
document.contentTypeanddocument.contentTypeRendered - Fixed
document.contentRenderedon files that do not have layouts - Added tests for:
- Checking that
ignored: truedocuments are properly ignored - That ignored common pattern files/dirs are properly ignored
- That attributes are being applied properly
- Checking that
- Updated balUtil from 1.4 to 1.5
- Fixes some scandir bugs
- Updated watchr from 1.0 to 2.0
- This should make watching re-generation a lot faster
- Added a warning if you have no plugins loaded and are trying to do a generate
- Fixed ignored check on documents
- Models are now Backbone Models
- Upgraded Query-Engine version from 0.6 to 1.1
- Plugins are now managed by npm and are no longer bundled with DocPad
- You will need to add them to your website's
package.jsonand install them vianpm install docpad-plugin-#{pluginName} - We now scan the
node_modulesandpluginsdirectories of your website for docpad plugins- These paths can be customised via the
pluginsPathsvariable in the docpad configuration
- These paths can be customised via the
- DocPad detects if something is a plugin by checking for the
docpad-pluginkeyword in thepackage.jsonfile, or if the file follows the#{pluginName}.plugin.coffeenaming convention
- You will need to add them to your website's
- CoffeeScript dependency is now bundled inside, instead of being an external dependency
- A website's npm dependencies are now installed as part of the initialisation process
- This is a big backwards compatibility break, previous skeletons and plugins need to upgraded
- Refer to the Upgrade Guide for instructions
- Fixed DocPad from outputting
undefinedinstead the layout's name which it could not find- Thanks to Changwoo Park for pull request #173 and Morgan Sutherland for issue #172
- Feedr Plugin now exposes
@feedr.feedsto thetemplateDatainstead of@feeds - Exchange data now moved to the docpad-extras repository
- Fixed broken
balupton.docpadskeleton repo url
- Added support for partials, with the new Partials Plugin
- Added support for caching remote assets, with the new Cachr Plugin
- Added support for caching and parsing remote feeds, with the new Feedr Plugin
- Added support for independent plugin unit tests
- Added support for specifying
templateDatafor the docpad configuration - Skeletons are no longer cached
- Caching skeletons was causing far too many problems
- Will now always use the local npm installation
- Added
gitPathandnodePathto docpad configuration - Split a document's
titleintotitleandname- Use
titlefor page titles (e.g.<title>page title</title>) - Use
namefor navigation listings - This was introduced as sometimes you want a different title for your page title, than for your navigation page names
- Use
- Cleaned up the plugin event system
- When an error occurs we will send an error report back to DocPad using AirBrake
- To turn this off, set
reportErrorsin your docpad configuration tofalse
- To turn this off, set
- Files, Documents, Layouts and Partials are now proper "models" and are now found in the
lib/modelsdirectory - Moved out some unstable or not as popular plugins to the docpad-extras repository, plugins moved are:
- Admin
- Authenticate
- AutoUpdate
- Buildr
- HTML2Jade
- Move
- PHP
- REST
- Roy
- Ruby
- Fixed missing interpolation on new version notification
- Fixed the scandir error with the skeletons path when doing the first run on windows
- Updated paths to use
path.joininstead of always using forward slashes
- Fixed Pygments plugin highlighting the code multiple times for documents with layouts
- Added
isLayoutandisDocumentflags toDocumentandLayoutprototypes
- Fixed ruby rendering with ruby v1.8
- Thanks to Sorin Ionescu for the patch
- The
enabledPluginsconfig option will now correctly only overwrite the default values if you have set it to be a string- Before it would always incorrectly overwrite the default value if set, which would cause some experimental disabled-by-default plugins to enable
- Added a Pygments Syntax Highlighting plugin
- It is disabled by default as not everyone would want syntax highlighting, to enable it, add the following to your website's
package.jsonfile:"docpad": { "enabledPlugins": { "pygments": true } }
- Thanks to Doug Neiner for urging it along
- It is disabled by default as not everyone would want syntax highlighting, to enable it, add the following to your website's
- Added a new
renderDocumentplugin event- It is fired after the extensions are rendered, but before the document is rendered inside its layout
- Useful for things that modify the rendered result of a document, e.g. syntax highlighting, paging, etc
- Closes
- Stopped
docpad renderfrom outputting the welcome message - Removed
try..catchs from plugins, you should do this too- The checking is now higher up in the callstack, which provides better error reporting and capturing
- Fixed a problem with the error bubbling that was preventing template errors from being outputted
- Fixed the "too many files open" issue thanks to bal-util's
openFileandcloseFileutility functions - Closes
- #143 - No errors on wrong layout
- Cleaned architecture
- Added unit tests (uses mocha)
- Better source code documentation
- Moved changelog from
README.mdtoHistory.mdas it was starting to get a bit long - Added
File.writeRendered - Added
File.contentRenderedWithoutLayout - Watching will no longer watch hidden files
- Added support for
- Added the ability to render files programmatically via the command line
- See the readme for usage instructions and more information
- Backwards compatibility breaks
- File property names have been changed
- New plugin structure
- Added offline installation support
- Added skeleton selection
- Added npm scripts for testing, installing and updating
- Closes
- #130 - As a Maintainer, I want unit tests, so that I can automatically ensure everything works
- #127 - As a User, I want support for Move, so I can write my javascript in my preferred language
- #122 - As a User, I want to be able to get the rendered content without the layout, so that I can include it inside other documents
- #98 - As a User, I want offline creation, so I can create new docpad projects offline
- #97 - Watching is unusable when combined with hidden files from IDEs and SVN
- #57 - Offline Setup: Skeletons needs to be cached for future offline installs
- #55 - As a User, I want support for Moustache, so that I can use my preferred markup
- Added an interactive cli
- Closes
- #125 - As a User, I want an Interactive CLI, so that I can do more with DocPad's CLI
- Added a new event system
- Closes
- #60 - DocPad needs a better event system
- Transferred DocPad's ownership from Benjamin Lupton to Bevry (Benjamin's company)
- Things that have changed
- It is now easier for us to manage DocPad, its extensions, collaborators and future repositories
- Thanks to Github's excellent organisation functionality - https://github.com/blog/674-introducing-organizations
- DocPad is now supported and backed by a commercial entity, meaning that it won't go away
- It is now easier for us to manage DocPad, its extensions, collaborators and future repositories
- Things that won't change
- DocPad will remain free as in beer, and free as in freedom
- DocPad will remain awesome
- If you are working on a cloned version of docpad, be sure to update your docpad's git repo address
- Things that have changed
- Fixed plugin priorities #115
- Thanks to Changwoo Park
- Updated dependencies
- Growl 1.2.x -> 1.4.x - changelog
- CoffeeScript 1.1.3 -> 1.2.x - changelog
- Swapped out Dominic Baggott's Markdown.js for Isaac Z. Schlueter's Github-Flavored-Markdown
- Now adds support for inline html in markdown files
- Closes #107
- Now adds support for inline html in markdown files
- Fixed plugin installation on windows
- Fixed the error:
Object #<Object> has no method 'error'- Fixes #106
- Can now pass over options to the coffeekup renderer inside the coffee plugin
- E.g. set
docpad: plugins: coffee: coffeekup: format: trueto have it tidy the html output - Thanks to Changwoo Park
- E.g. set
- Disabled the following plugins by default
- Admin
- Authenticate
- Rest
- AutoUpdate
- Buildr
- Html2Jade
- Updated dependencies
- Commander 0.3.x -> 0.5.x - changelog
- Growl 1.1.x -> 1.2.x - changelog
- NPM 1.0.x -> 1.1.x
- Jade 0.17.x -> 0.19.x - changelog
- Stylus 0.19.x -> 0.20.x - changelog
- Nib 0.2.x -> 0.3.x - changelog
- AutoUpdate plugin
- Automatically refreshes the user's current page when the website is regenerated
- Very useful for development, though you probably want to disable it for production
- Enabled by default
- Heroku server support
- Added
extendServerconfiguration option- Now, by default, even if the server is provided, we will extend it. If you do not want this, set this configuration option to
false.
- Now, by default, even if the server is provided, we will extend it. If you do not want this, set this configuration option to
- Made it easier to load docpad as a module
- Instead of crashing when an uncaught error happens, it'll output it and keep running
- The log messages and next handling in
docpad.actionhas been cleaned up- Now those log messages are contained within the default next handler, so if you provide a custom default next handler you'll have to do your own success log messages
- NPM is now installed locally
- This is to ensure it's availability on cloud servers
- DocPad will now try and figure out the node executable location to provide greater compatibility on cloud servers
- If the plugin installations are taking a while, you'll get informed of this, rather than just staring at a blank blinking cursor
- Roy plugin
- Adds Roy to JavaScript support
.js.roy
- Adds Roy to JavaScript support
- Windows support!
- Now uses Benjamin Lupton's Watchr as the watcher library
- Provides windows support
- Now uses Tim Caswell's Haml.js as the haml library
- Provides windows support
- Bug fixes
- Works with zero documents
- Works with empty
package.json - Fixed mime-type problems with documents
- Support for dynamic documents
- These are re-rendered on each request, must use the docpad server
- See the search example in the kitchensink skeleton
- Removed deprecated
@Document,@Documents, and@Sitefrom thetemplateData(the variables available to the templates). Use their lowercase equivalents instead. This can cause backwards compatibility problems with your templates, the console will notify you if there is a problem. - Fixed
docpad --versionreturningnullinstead of the docpad version
- Upgrade guide for 1.x users
- Tested and working on Node 0.4, 0.5, and 0.6
- Windows support is still to come - track it's progress here
- Configurable via
package.json- DocPad is now configurable via its and your website's
package.jsonfile
- DocPad is now configurable via its and your website's
- New plugin architecture
- Plugins must now be isolated in their own directory
- Plugins can now have their own
package.jsonfile- Use this for specifying plugin configuration, dependencies, etc
- Plugin events have been renamed to before/after
- New before/after events have been added
docpadandloggerare now local variables, rather than passed arguments- Arguments are still kept for backwards compatibility - this may change
- Generation changes
- Rendering is now a 2-pass process
- Contextualize is now a sub-step of parse, instead of it's own main step
- Better simplicity, less complexity
- Documents can now have multiple urls
- These are customisable via the document's
urlsarray property
- These are customisable via the document's
- Plugin Changes
- REST plugin supports saving document data via POST (disabled by default)
- Administration plugin adds front-end admin functionality (disabled by default)
- See the client side editing example in the kitchensink skeleton
- SASS plugin
- Adds SASS to CSS support
- Uses TJ Holowaychuk's Sass.js - https://github.com/visionmedia/sass.js
- Adds SASS to CSS support
- Coffee Plugin
- Removed CoffeeCSS support as it had problems
- Template engines now have access to node.js's
require - Less Plugin
- Added LessCSS to CSS support
- Uses Alexis Sellier's Less.js
- Added LessCSS to CSS support
- Fixed NPM warning about incorrect property name
- Logged errors will now also output their stacktraces for easier debugging
- If an error occurs during rendering of a document, docpad will let us know which document it happened on
- Parsing is now split into two parts
parsingandcontextualizing- Contextualizing is used to determine the result filename, and title if title was not set
- The code is now more concise
- File class moved to
lib/file.coffee - Prototypes moved to
lib/prototypes.coffee - Version checking moved to the
bal-utilmodule
- File class moved to
- File properties have changed
basenameis extensionlessfilenamenow contains the file's extensionsidis now therelativeBaseinstead of theslugextensionRenderedis the result extensionfilenameRenderedis the result filename: `"#{basename}.#{extensionRendered}"titleif now set tofilenameRenderedif not set
- Added support for different meta parsers, starting with CoffeeScript and YAML support. YAML is still the default meta parser
- The YAML dependency is specifically set now to v0.2.1 as the newer version has a bug in it
- Fixed multiple renderers for a single document. E.g.
file.html.md.eco - Now also supports using
###along with---for wrapping the meta data - Supports the
publicalias for thefilesdirectory
- Plugins now conform to a
.plugin.coffeenaming standard - Dependencies now allow for minor patches
- Stylus Plugin
- Added Stylus to CSS support
- Uses TJ Holowaychuk's Stylus
- Added Stylus to CSS support
- Jade Plugin
- Added HTML to Jade support
- Uses Don Park's Html2Jade
- Added HTML to Jade support
- Coffee Plugin
- Added CoffeeCSS to CSS support
- Uses James Campos's CCSS
- Added CoffeeCSS to CSS support
- Fixed incorrect date sorting for documents
- Thanks to Olivier Bazoud
- Added Buildr Plugin so you can now bundle your scripts and styles together :-)
- The
actionmethod now supports an optional callback- Thanks to Aaron Powell for #41
- Added a try..catch around the version detection to ensure it never kills docpad if something goes wrong
- Skeletons have been removed from the repository due to circular references. The chosen skeleton is now pulled during the skeleton action. We also now perform a recursive git submodule init and update, as well as a npm install if necessary.
- Upgrade guide for v0.x users
- The concept of template engines and markup languages have been merged into the concept of renderers
- Coffee Plugin
- Added CoffeeKup to anything and HTML to CoffeeKup support
- Added CoffeeScript to JavaScript and JavaScript to CoffeeScript support
- Added a Commander.js based CLI
- Thanks to ~eldios
- Added support for Growl notifications
- Added asynchronous version comparison
- Plugin infrastructure
- Better logging through Caterpillar
- HAML Plugin
- Added HAML to anything support
- Uses TJ Holowaychuk's HAML
- Added HAML to anything support
- Jade Plugin
- Added Jade to anything support
- Uses TJ Holowaychuk's Jade
- Added Jade to anything support
- No longer uses MongoDB/Mongoose! We now use Query-Engine which doesn't need any database server :)
- Watching files now working even better
- Now supports clean urls :)
- Now supports multiple skeletons
- Structure changes
- Now supports multiple docpad instances
- Moved to CoffeeScript
- Removed highlight.js (should be a plugin or client-side feature)
- Pretty big clean
- The CLI is now working as documented
- Got the generation and server going
- Initial prototyping with Sven Vetsch
- Initial discussions with Henri Bergius