GithubHelp home page GithubHelp logo

chrisdmacrae / front-matter-manipulator Goto Github PK

View Code? Open in Web Editor NEW
24.0 2.0 1.0 210 KB

A utility for parsing and manipulating documents with Front Matter

Home Page: https://chrisdmacrae.github.io/front-matter-manipulator

JavaScript 100.00%
static-site static-site-generator front-matter cli nodejs node npm npm-package

front-matter-manipulator's Introduction

Hi there ๐Ÿ‘‹

Hi there, I'm Chris. I'm a designer, full stack developer, writer, father and husband.

I work at Careguide, where I am the lead engineer, leading a team of 8 developers and 2 designers, helping care providers connect with families to bring care to the world.


Background

I've been working in tech since 2013. I started my career as a designer, graduating with an associates diploma in interdiscplinary design.

I spent two years working in marketing as a brand designer. Then I spent two years as a product designer working exclusively on mobile apps. After that I spent roughly two years running my own business offering branding, search engine optimization, and inbound marketing services, which I then closed shop on and handed off all of my clients.

I've spent the last four years working as a fullstack developer. I've gotten to work as a team lead, technical project manager, and scrum master (for better or for worse).

Location

Morell Area

I live and work from beautiful, seaside, Morell, Prince Edward Island in Eastern Canada.

Links

front-matter-manipulator's People

Contributors

chrisdmacrae avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

lunaticmuch

front-matter-manipulator's Issues

Convert to fully async, promise-based

Problem we're trying to solve

Currently the commands are written partially synchronous, which means the I/O can be blocked when reading many files or updating many files.

Moving to promise-based async will allow the commands to run much faster.

General

  • Update update to be async
  • Update rename to be async
  • Update valuesto be async
  • Update fields to be async

Specific

  • Update all array functions to be async
  • Update all readFileSync and writeFileSync to be async
  • Update all glob actions to be async

Add drop command

Problem's we're trying to solve

In some cases you may have a bunch of extra fields that you no longer need, being able to batch remove them from many files is ideal.

Currently, either the CMS you use must do this, you must do it by hand, or by writing a script.

  • Allow specifying many fields to be dropped from the globbed files
  • Ensure that a confirmation is used by default, as this destructive behaviour is not easily undone without version control

Add a merge command

Problem's we're trying to solve

In some cases, you may have many fields that are very similar or are used for the same purpose, and want to consolidate these to have leaner FMTs.

This currently requires a lot of tedious, manual work. Having a utility that finds all possible values for each key, and allows you to merge them / pick a preferred value for a single (or new key) would be ideal for site migration and updating.

  • Add ability to query the values of a file by key
  • Allow the specification of the replacement key
  • Prompt the user for the correct value
  • Allow the user to optionally specify a "winner cascade", where values don't need to be confirmed, but are used in order found. (E.g, --by-fields description,summary,excerpt)

Add ability to add new data set

It would really be great if update was able to add a new data key/value pair when passing an in-existing key as argument.

The current behaviour when doing the above is a successfully updated list of items. Yet the data set is not added.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.