docpad-plugin-combiner
Advanced tools
Comparing version 2.0.6 to 2.0.7
@@ -24,3 +24,8 @@ // Generated by CoffeeScript 1.6.3 | ||
CombinerPlugin.prototype.config = { | ||
collectionName: "combineOut" | ||
collectionName: "combineOut", | ||
comparator: [ | ||
{ | ||
filename: 1 | ||
} | ||
] | ||
}; | ||
@@ -37,7 +42,9 @@ | ||
CombinerPlugin.prototype.extendCollections = function(opts) { | ||
var config, docpad, locale; | ||
var docpad, locale, pluginConfig; | ||
docpad = this.docpad; | ||
locale = this.locale; | ||
config = this.getConfig(); | ||
docpad.setCollection(config.collectionName, docpad.database.createLiveChildCollection().setQuery('isCombine', { | ||
pluginConfig = this.getConfig(); | ||
docpad.setCollection(pluginConfig.collectionName, docpad.database.createLiveChildCollection(null, { | ||
comparator: pluginConfig.comparator | ||
}).setQuery('isCombine', { | ||
combine: true | ||
@@ -64,3 +71,3 @@ }).on('add', function(model) { | ||
} | ||
return; | ||
return this; | ||
} | ||
@@ -71,3 +78,3 @@ if (combineOutCollection.length === 0) { | ||
} | ||
return; | ||
return this; | ||
} | ||
@@ -74,0 +81,0 @@ combineOutContent = {}; |
{ | ||
"name": "docpad-plugin-combiner", | ||
"version": "2.0.6", | ||
"version": "2.0.7", | ||
"description": "A Docpad plugin that adds the ability to combine parts to create a final master file", | ||
@@ -5,0 +5,0 @@ "homepage": "https://github.com/pflannery/docpad-plugin-combiner", |
@@ -25,3 +25,3 @@ # Combiner Plugin for [DocPad](http://docpad.org) | ||
function foo(){} | ||
* anothTest.js.coffee | ||
@@ -36,4 +36,3 @@ | ||
bar -> | ||
* **out**: scripts/myScript.js: | ||
@@ -47,6 +46,6 @@ | ||
bar(function() {}); | ||
## Install | ||
``` | ||
```shell | ||
npm install --save docpad-plugin-combiner | ||
@@ -57,6 +56,8 @@ ``` | ||
``` | ||
```cson | ||
combiner: | ||
# default collection name | ||
collectionName: "combineOut" | ||
# default sort comparator, for more info on comparators see [Query Engine Guide](http://bevry.me/queryengine/guide) | ||
comparator: [filename: 1] | ||
``` | ||
@@ -63,0 +64,0 @@ |
No bug tracker
MaintenancePackage does not have a linked bug tracker in package.json.
Found 1 instance in 1 package
No bug tracker
MaintenancePackage does not have a linked bug tracker in package.json.
Found 1 instance in 1 package
9558
109
65