New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

grunt-pages

Package Overview
Dependencies
Maintainers
1
Versions
31
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

grunt-pages - npm Package Compare versions

Comparing version 0.2.2 to 0.2.3

dev/blog/index.html

4

package.json
{
"name": "grunt-pages",
"version": "0.2.2",
"version": "0.2.3",
"description": "Grunt task to generate a blog.",

@@ -12,3 +12,3 @@ "main": "Gruntfile.js",

"pygmentize-bundled": "~1.0.1",
"marked": "git://github.com/ChrisWren/marked.git#dcbb4e22edfc96a3a9ec38ec4cc8c35682c8290c",
"marked": "git://github.com/ChrisWren/marked.git#14b61ad95e78d6df4ad9cbaca41dee699ad68443",
"js-yaml": "~2.1.0"

@@ -15,0 +15,0 @@ },

@@ -148,2 +148,4 @@ # grunt-pages

**0.2.3** - Ignore dotfiles, error reporting for incorrect data JSON files, and new header anchor link format.
**0.2.2** - Used forked version of marked to enable header anchor links.

@@ -150,0 +152,0 @@

@@ -25,3 +25,3 @@ 'use strict';

var numPosts = grunt.file.expand({ filter: 'isFile' }, [this.data.src + '/**', '!**/_**']).length;
var numPosts = grunt.file.expand({ filter: 'isFile' }, [this.data.src + '/**', '!**/_**', '!**/.**']).length;
var parsedPosts = 0;

@@ -31,4 +31,4 @@ var postCollection = [];

grunt.file.recurse(this.data.src, function (abspath) {
// Don't include draft posts
if (path.basename(abspath).indexOf('_') === 0) {
// Don't include draft posts or dotfiles
if (path.basename(abspath).indexOf('_') === 0 || path.basename(abspath).indexOf('.') === 0) {
return;

@@ -61,6 +61,10 @@ }

if (options.data) {
templateData.data = JSON.parse(fs.readFileSync(options.data));
try {
templateData.data = JSON.parse(fs.readFileSync(options.data));
} catch (e) {
grunt.fail.fatal(e + ' when parsing ' + options.data);
}
}
postCollection = generatePosts(templateData, abspath);
generatePosts(templateData, abspath);
if (options.pageSrc) {

@@ -177,4 +181,2 @@ generatePages(templateData);

});
return postCollection;
}

@@ -194,2 +196,7 @@

// Don't include dotfiles
if (path.basename(abspath).indexOf('.') === 0) {
return;
}
// Don't generate the paginated list page

@@ -196,0 +203,0 @@ if (abspath !== listPage) {

Sorry, the diff of this file is not supported yet

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