dxprog / anime-bracket

The code that runs animebracket.com
http://animebracket.com
84 stars 20 forks source link
hacktoberfest

Build Status

Brakkit

A site for running standard elimination style brackets.

Things you'll need to run brakkit

Configuration and Installing

Configuration

Brakkit is set up to allow multiple front-ends to be run with a single back-end. As such, there are two config files:

Installing

Database

To bootstrap your database, use your favorite SQL execution method of choice to run the queries in database.sql. You can do so from the commandline as follows:

mysql -u USER_NAME -p DATABASE_NAME < bracket.sql

At this point, you'll want to set the values in config.php to connect to your database.

Building Static Assets

You'll need node and npm for the following. If you don't have these, I recommend using nvm to install these on your system. Due to limitations with node-sass, node 14.x is the latest version of node currently supported.

Once you've installed that (or if you already have node), run the following to build all of the static content:

npm install
npm run build

This will build the following files that you'll want to ensure are served from your front-end:

dist/static/
├─css/
├────anime-bracket.css
├─js/
└────anime-bracket.min.js

While developing, you can run the static asset builder in watch mode so that the project is rebuilt as you develop:

npm start