Skip to content
Permalink
Browse files

Updated script to write date metadata

  • Loading branch information
davidmerfield committed Dec 16, 2019
1 parent f10fd0a commit 6cbfd8b2a1fc4b55bc2ce61fcc849138fd6141b3
Showing with 1 addition and 3 deletions.
  1. +1 −3 scripts/blog/write-data-metadata.js
@@ -8,14 +8,12 @@ var SUPPORTED_EXTENSIONS = ['.txt', '.md'];
var FORMAT = 'M/D/YY';
require("moment-timezone");
get(process.argv[2], function(err, user, blog) {
console.log('')
var client = require("../../app/clients")[blog.client];
Entries.each(
blog.id,
function(entry, next) {
var contents, hasMetadata, dateMetadata;
if (entry.deleted || entry.page) return next();
if (entry.metadata.date) return next();
if (entry.deleted || entry.page || entry.metadata.date) return next();
if (SUPPORTED_EXTENSIONS.indexOf(path.extname(entry.path).toLowerCase()) === -1) {
console.log(entry.path, 'Cannot add metadata to unsupported file type')
return next();

0 comments on commit 6cbfd8b

Please sign in to comment.
You can’t perform that action at this time.