Skip to content

mathbookio/mathbook

Repository files navigation

Build Status Greenkeeper badge Gitter chat

mathbook-logo

Mathbook is an online repository of peer-reviewed tutorials on topics covering a wide range of subjects in Mathematics. It's open source and open to anyone who is interested in creating or reviewing a tutorial. The project itself is written in JavaScript and built using NodeJS, ExpressJS, Riot and Pug.

Requirements

  • Node 8.x
  • Redis 4.x

Up and Running with Docker

Please refer to the wiki to get up and running with Docker.

Local Installation & Setup

Download/Clone Mathbook Repo & Install Dependencies

git clone https://github.com/mathbook-io/mathbook.git

cd ./mathbook

# install dependencies
npm i

Additional Steps

[required] - You will need a custom configuration file tailored to your local setup so go ahead and create a file in the config folder called local.json. You can grab a sample local config file from the wiki here.

[optional] - This step if only needed if you want to get the authentication functionality of Mathbook to work. There is a wiki page to get that up and running since its not required for a local setup.

Downloading & Installing Redis

# linux users
wget http://download.redis.io/redis-stable.tar.gz
tar xvzf redis-stable.tar.gz
cd redis-stable
make
make test
make install

# mac osx users
brew install redis

Starting Up A Redis Server

redis-server

Starting Up Mathbook

Note: You might need to install gulp and bunyan globally first

npm i -g gulp-cli bunyan
cd ./mathbook

# bundle the js and css files
gulp bundle

# start up the server
gulp serve

# if you want pretty log formatting
gulp serve | bunyan

Testing

# run all tests
gulp test

Note: if the above test commands fail, you might need to install gulp and bunyan globally

Contributing

If you are interested in contributing please refer to CONTRIBUTING.md

Contributors

If you are looking for the list of Contributors of Mathbook, please refer to contributors.md

License

Mathbook is Open Source and Licensed under MPL-2.0 Please refer to LICENSE for more info.