@tomsd/md-server

2.1.0 • Public • Published

@tomsd/md-server

Installation

npm install @tomsd/md-server

Usage

Initializing

npx mdc --init

open md-server.config.js and fill your MongoDB uri.

To Serve

npx mds --start

see the page with your browser http://localhost:3000/

or deploy it on your Heroku or some platforms.

To Edit

npx mdc --add directory/ofmine --file md

You can edit the markdown file when the file in your directory is generated.

To Save

npx mdc --save directory/ofmine/ --file md

The web server will serve the markdown as html. see in your browser: http://localhost:3000/md/directory/ofmine/

To clear your local directory

npx mdc --clear

To Get

npx mdc --get directory/ofmine/ --file md

about GitHub limit

mdc mdc --save what/ever/ --file md command will send a HTTP request for each md file. The limit count of anonymous request will be up to 60 times in an hour, and the limit will increase 5000 times in an hour if Basic Authentication is provided.

The dotenv file can indicate the user and token for the command.

  1. make an .env
  2. write your user name and personal access token in it
  3. then Basic Authentication will be enabled, limit count will be up.
GITHUB_USER=your_github_user
GITHUB_USER_TOKEN=personal_access_token

Readme

Keywords

Package Sidebar

Install

npm i @tomsd/md-server

Weekly Downloads

0

Version

2.1.0

License

MIT

Unpacked Size

2.99 MB

Total Files

30

Last publish

Collaborators

  • tomsd