apex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sas...@apache.org
Subject incubator-apex-site git commit: APEXCORE-311 #resolve Adding improved date formatting to releases page
Date Thu, 21 Jan 2016 01:33:55 GMT
Repository: incubator-apex-site
Updated Branches:
  refs/heads/master 8602d9b8d -> 90df00c1f


APEXCORE-311 #resolve Adding improved date formatting to releases page


Project: http://git-wip-us.apache.org/repos/asf/incubator-apex-site/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-apex-site/commit/90df00c1
Tree: http://git-wip-us.apache.org/repos/asf/incubator-apex-site/tree/90df00c1
Diff: http://git-wip-us.apache.org/repos/asf/incubator-apex-site/diff/90df00c1

Branch: refs/heads/master
Commit: 90df00c1fc74c1b6958f711325baca371d0e6f3c
Parents: 8602d9b
Author: sashadt <sasha@datatorrent.com>
Authored: Wed Jan 20 17:33:49 2016 -0800
Committer: sashadt <sasha@datatorrent.com>
Committed: Wed Jan 20 17:33:49 2016 -0800

----------------------------------------------------------------------
 gulpfile.js  | 3 ++-
 package.json | 1 +
 2 files changed, 3 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-apex-site/blob/90df00c1/gulpfile.js
----------------------------------------------------------------------
diff --git a/gulpfile.js b/gulpfile.js
index 0ad3be0..9966144 100644
--- a/gulpfile.js
+++ b/gulpfile.js
@@ -14,6 +14,7 @@ var _ = require('lodash');
 var exec = require('child_process').exec;
 var semver = require('semver'); 
 var naturalSort = require('javascript-natural-sort');
+var dateFormat = require('dateformat');
 
 // Constants
 var TEMP_PARTIAL_LOCATION = './.tmp/partials/';
@@ -64,7 +65,7 @@ gulp.task('html', ['md2html'], function() {
     helpers: {
       releaseDate: function(timestamp) {
         var d = new Date(timestamp);
-        return [d.getFullYear(), d.getMonth() + 1, d.getDate()].join('-');
+        return dateFormat(d, "yyyy-mm-dd");
       }
     }
   };

http://git-wip-us.apache.org/repos/asf/incubator-apex-site/blob/90df00c1/package.json
----------------------------------------------------------------------
diff --git a/package.json b/package.json
index f584345..deb79b7 100644
--- a/package.json
+++ b/package.json
@@ -23,6 +23,7 @@
   "dependencies": {
     "async": "^1.5.0",
     "bower": "^1.5.2",
+    "dateformat": "^1.0.12",
     "gulp": "^3.9.0",
     "gulp-compile-handlebars": "^0.5.0",
     "gulp-less": "^3.0.3",


Mime
View raw message