• This project
    • Loading...
  • Sign in

Shenlin / markdown-view

Itomix
Go to a project
Toggle navigation Toggle navigation pinning
  • Projects
  • Groups
  • Snippets
  • Help
  • Project
  • Activity
  • Repository
  • Pipelines
  • Graphs
  • Issues 0
  • Merge Requests 0
  • Wiki
  • Snippets
  • Network
  • Create a new issue
  • Builds
  • Commits
  • Issue Boards
  • Files
  • Commits
  • Network
  • Compare
  • Branches
  • Tags
Switch branch/tag
  • markdown-view
  • bin
  • mdview
  • lintry's avatar
    init · a3030c30
    a3030c30
    lintry authored 2016-10-26 18:14:57 +0800
mdview 338 Bytes
Raw Blame History Permalink
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
#!/usr/bin/env node

"use strict";

var target = process.argv[2];

if (!target) {
  console.error('target file is not found!');
  process.exit(1);
}

const mdview = require('../lib/mdview')(),
  path = require('path');

const filename = path.resolve(process.cwd(), target);
var result = mdview.renderFile(filename);

console.log(result);