Skip to content

stevefranchak/wedding-website

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

33 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

wedding-website

Install

Node.js and its package manager npm are required dependencies. The following versions were used for development:

  • node -> 6.7.0
  • npm -> 3.10.3

Once these dependencies are installed and the git repo cloned, execute the following to install all the node dependencies:

npm -g install grunt-cli
npm install

Build

The JavaScript task runner grunt is used to build wedding-website.

grunt

Flags

  • --prod - Builds wedding-website for production, uglifying the generated JS and CSS files
  • --watch - Watches js/lib/**, js/deps/**, and scss/** for file changes and rebuilds

Test Server

The wedding-website repository contains a Python 2.7.x HTTP server that serves the files in the "site" directory created by the grunt build.

Running with Grunt

If the system is a Unix environment, the server can be started via grunt like so:

# The server listens on port 8000 by default
grunt server

The port that the server listens on can be changed by passing the argument --port=<port>:

grunt server --port=8881

Note: Not all output from test_server.py is outputted when running the server with grunt. This seems to be an issue with grunt-shell.

Running directly

Alternatively, the server can be started by being invoked directly:

# The server listens on port 8000 by default
./test/test_server.py

The port that the server listens on can be changed like so:

./test/test_server.py 8881