Quick and flexible web project generator for standalone sites or use with QEDServer.

View the Project on GitHub napcs/qedproject

What is QEDProject?

QEDProject creates a simple web project skeleton with support for Sass and CoffeeScript as well as asset packaging, LiveReload support, and JavaScript testing.

It also goes great with http://qedserver.napcs.com/


QEDProject is distributed as a Ruby gem. That means you'll need the Ruby programming language installed on your machine along with the RubyGems package manager.

Then, simply

$ gem install qedproject

to get the latest version and all its dependencies.

If you're on Windows, you'll need to install RubyInstaller and the Devkit. See http://rubyinstaller.org/add-ons/devkit/ for more.

If you're on OSX, you need to have XCode installed.

If you're on Ubuntu and you want to use CoffeeScript, you'll need to install NodeJS.


Generate a simple web project

$ qedproject myproject
$ cd myproject

Then open the public/index.html file in your browser and get to work. Of course, this is only the tip of the iceberg.

CoffeeScript and Sass support

To generate a simple web project with CoffeeScript and Sass support, using Guard to monitor files for changes.

qedproject myproject -c -s

Once the project is created, go into the project folder and run the Guard command.

cd myproject

As you work on the Sass and CoffeeScript files, the corresponding CSS and JS files will be placed in public/javascripts and public/stylesheets respectively.

Asset Packaging with Jammit

Generate a project that minifies CSS and JS files using Jammit. Creates the asset configuration file and a Guardfile.

$ qedproject myproject -a

Create a project with CoffeeScript, Sass, and asset packaging support, using Guard.

$ qedproject myproject -c -s -a

Including JavaScript libraries.

Create a new project using jQuery

$ qedproject myproject -l jquery

Create a new project using jQuery and Backbone

$ qedproject myproject -l jquery,backbone

Create a new project using jQuery and Backbone, but also with Sass, CoffeeScript, and asset packaging.

$ qedproject myproject -l jquery,backbone -c -s -a

Creating projects with Jasmine BDD tests

If you'd like to create projects where you can do Jasmine testing, use the -t flag.

$ qedproject myproject -l jquery,backbone -c -s -a -t

This will create a suite.html file in the spec folder, and will create a sample spec. If you asked for CoffeeScript, the sample spec will be written in CoffeeSript and the Guardfile will be modified to convert specs to js files.

And if you used jQuery, the jasmine-jquery library will be added to your test suite.

Using the Server and LiveReload

You can use the -r flag to add LiveReload support to the project.

$ qedproject myproject -r -c -s -a -t -l jquery

You can make your browser refresh when you change your files. To do that, first open another window and type

$ cd myproject
$ qedproject --server

which starts up a web server on port 1337 that serves up your project's public folder. Then install one of the LiveReload plugins for your browser and connect your browser by visiting http://localhost:1337 and activating LiveReload.

To get the browser plugins, visit http://help.livereload.com/kb/general-use/browser-extensions

Overwriting files

By default, the CLI tool will not overwrite files with the same name. If you want to replace files, pass the -o flag.