Git Product home page Git Product logo

doctool's Introduction

doctool

Tool for editing Valence UI-themed sites generated from Markdown

Setup

You'll probably want to install this globally with -g. Run this:

npm install -g https://github.com/Brightspace/doctool

Running a build server

Well run the tool on the example project in this repo. First, clone the repo

git clone https://github.com/Brightspace/doctool
cd doctool

Next, start doctool in interactive mode:

doctool --interactive example

Your browser will open up a window to the rendered webpage. You can edit files in your favourite editor and the pages will render and reload when you save.

For maximum effect, try using Visual Studio Code with the following user settings:

{
  "files.autoSave": "afterDelay",
  "files.autoSaveDelay": 300
}

Doing a single build

Just remove the --interactive flag

doctool example

CLI options

Usage: doctool <inputDir> [<outputDir>] OPTIONS

Arguments       Default    Description
inputDir        -          input files directory
outputDir       .dist      output directory (relative to <inputDir> if applicable)

Options         Default    Description
--interactive   -          runs a web server and automatically re-renders and reloads browsers
--browser       true       open a browser
--wport         39983      web server port
--rport         39984      web-socket page refresh port
--verbose       -          verbose output
--notify        -          send notifications of changes to the OS
--help          -          this screen

Developing

See the section below on contributing. It is recommended that you first fork the repo. After that, clone it and enter the repositories directory on the command-line and run

npm install

to install the dependencies.

To stop yourself from going insane, you'll probably want the --no-browser argument when using --interactive to avoid spamming your tab bar.

./src/cli.js --interactive --no-browser example

Contributing

  1. Fork the repository. Committing directly against this repository is highly discouraged.
  2. Make your modifications in a branch, updating and writing new tests.
  3. Ensure that all tests pass
  4. rebase your changes against master. Do not merge.
  5. Submit a pull request to this repository. Wait for tests to run and someone to chime in.

doctool's People

Contributors

j3parker avatar

Watchers

Sarah-Beth Bianchi avatar

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.