Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

metalsmith

Package Overview
Dependencies
Maintainers
2
Versions
50
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

metalsmith - npm Package Compare versions

Comparing version 0.4.0 to 0.5.0

6

History.md
0.5.0 - March 21, 2013
----------------------
* remove destination directory when writing
* expose `#run` to run middleware stack
* fix jade examples
0.4.0 - March 14, 2013

@@ -3,0 +9,0 @@ ----------------------

20

lib/index.js

@@ -10,2 +10,3 @@

var readdir = require('recursive-readdir');
var rm = require('rimraf');
var utf8 = require('is-utf8');

@@ -107,3 +108,2 @@ var Ware = require('ware');

fn = fn || noop;
var ware = this.ware;
var self = this;

@@ -113,3 +113,3 @@

if (err) return fn(err);
ware.run(files, self, function(err){
self.run(files, function(err, files){
if (err) return fn(err);

@@ -124,2 +124,13 @@ self.write(files, function(err){

/**
* Run a set of `files` through the middleware stack.
*
* @param {Object} files
* @param {Function} fn
*/
Metalsmith.prototype.run = function(files, fn){
this.ware.run(files, this, fn);
};
/**
* Read the source directory, parsing front matter and call `fn(files)`.

@@ -168,3 +179,6 @@ *

each(Object.keys(files), write, fn);
rm(dest, function(err){
if (err) return fn(err);
each(Object.keys(files), write, fn);
});

@@ -171,0 +185,0 @@ function write(file, done){

6

package.json
{
"name": "metalsmith",
"repository": "git://github.com/segmentio/metalsmith.git",
"version": "0.4.0",
"version": "0.5.0",
"license": "MIT",

@@ -35,7 +35,7 @@ "description": "An extremely simple, pluggable static site generator.",

"chalk": "^0.4.0",
"clone": "^0.1.11"
"clone": "^0.1.11",
"rimraf": "^2.2.6"
},
"devDependencies": {
"mocha": "1.x",
"rimraf": "~2.2.6",
"fs-readdir-recursive": "0.0.1",

@@ -42,0 +42,0 @@ "assert-dir-equal": "~0.1.0",

@@ -129,2 +129,6 @@ # Metalsmith

#### #run(fn)
Build with the given settings without writing the files to disk and call `fn(err, files)`.
#### #source(path)

@@ -131,0 +135,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc