1
0
mirror of https://github.com/tycrek/degoogle.git synced 2025-08-31 18:32:11 +02:00

Automate updating "Updated"; Updated is also now a badge

This commit is contained in:
tycrek
2020-06-01 15:43:40 -06:00
parent 032e818109
commit 594abe5738
4 changed files with 11 additions and 2 deletions

View File

@@ -3,12 +3,13 @@
const os = require('os');
const path = require('path');
const fs = require('fs-extra');
const moment = require('moment');
const YAML = require('yaml');
// A hacky sort of "class" to contain methods for each section
const BUILD_SECTION = {
// TODO: Make more of these YAML-based functions
header: () => readFile('md/_header.md'),
header: () => readFile('md/_header.md').replace('{{DATE}}', moment().format('MMMM Do YYYY @h:mm a').replace(/ /g, '%20')),
index: () => readFile('md/_index.md'),
contributing: () => readFile('md/_contributing.md'),
browserExtensions: () => generateBrowserExtensions(),