Skip to content

felicity-iiith/felicity18-website

Repository files navigation

Felicity '18

Build Status Scrutinizer Code Quality

This is the repository for the Felicity '18 website. [This is a fork of the Felicity '17 website]

Fork and Clone

In order to clone this repository, you will need to use the --recursive flag with git clone (or you could initialize the submodule later with git submodule update --init --recursive).

Felicity Email

For instructions on setting up felicity emails refer to this wiki.

Prerequisites

You will need an Apache server that can run PHP and a MySQL-compatiable server for the database. You will also need to install the mysqlnd mysql driver.

The prerequisites required to build and run the website are Node.js (with npm) and Composer.

If you need help installing these dependencies, please refer to INSTALL.md.

Install and Build

In order to build the development environment, cd into the root directory of this repo, become root if neccessary and run:

$ npm install # installs required npm packages
$ composer install # installs required composer packages
$ npm install -g gulp # globall install gulp, a task runner
# build the site and then watch for changes, rebuilding when updated
$ gulp watch

After running these commands, you'll have a built copy of the site in a build/ folder in the root of the project. You work in src/ and the built site goes to build/.

Also,

  • Copy src/app/config-sample.php to src/app/config.php and edit values (at least the database configuration).
  • Import the database.sql file into your database, you can do this by mysql -u username -p password DBNAME < database.sql
  • There are additional SQL files to import in /sql/ and if you already have a particular version of the database and want to upgrade, look at /sql/migrations/.
  • For pretty URLs (/hello/world/ instead of /index.php/hello/world/), copy the src/HTACCESS file and name it src/.htaccess. You probably need to edit the line RewriteBase / and replace it with the URL it is meant to be accessible in your server setup, followed by /build, such as maybe RewriteBase /felicity18-website/build.

Please contribute!