It also goes great with 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.
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 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.
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 guard
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
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
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.
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 localhost:1337 and activating LiveReload.
To get the browser plugins, visit help.livereload.com/kb/general-use/browser-extensions
By default, the CLI tool will not overwrite files with the same name. If you want to replace files, pass the -o flag.
Plugins should be gems that start with the prefix qedproject-.
Assuming we're making a plugin called “qedproject-prototype” for the Prototype library.
Make a structure like this:
qedproject-prototype lib/ plugins/ prototype.rb qedproject-prototype.rb version.rb vendor/ prototype/ prototype.js
Then your code will look like this for the prototype.rb file:
module QEDProject module Plugins class Prototype < QEDProject::Libraries::Base library :prototype, __FILE__ set_js_files ["prototype.js"] #set_css_files ["array", "of", "css", "files"] #set_image_files ["array", "of", "image", "files"] def generate! super # customizations of your own # if you have no customizations, just don't implement generate! at all. end end end end
When your plugin is installed as a gem, QEDProject will detect it and attempt to load it. It will actually load the gem itself, so you don't necessarily have to create a plugin with this - you could override any behavior you'd like.
Fork, send patches. Keep them small so I can pull them in.
2013-03-09 - 0.4.2
Fixed dependency issue with guard-livereload.
Seriously, last version that supports 1.8.7.
2013-02-17 - 0.4.1
Minor update of gem dependencies
Force Guard to use 1.4.0 for Ruby 1.8.7 compatibility
Last version that supports Ruby 1.8.7
2012-10-25 - 0.4.0
Change temp directory name from tmp to _qedtmp
jquery mpbile update to 1.2.0
Updated Skeleton to 1.2.0
Updated jquery to 1.8.2
Fixes the livereload inclusion bug that shows up with Guard.
Fixed a duplicate test name and added test case for Jasmine
Updated Jasmine to 1.2.0
Renamed Suite.html back to SpecRunner.html to be more standard
2012-4-30 - 0.3.2
* Fixed incorrect reference in suite.html for jasmine-jquery
2012-4-24 - 0.3.1
* Jasmine-jquery added. * Fixed the Jasmine template. * Made LiveReload an option instead of the default.
2012-4-19 - 0.3.0
* New projects get a Gemfile now to make it a little easier if you use Bundler * The Jammit guard now forces rebuilding the assets - it was getting stuck on CoffeeScript files and this fixes it. * JQuery Mobile 1.1 * Knockout 2.0.0 * Added a `--server` option which just starts up a simple web server pointing to the public/ folder of the current dir. * Fixed a bug where Skeleton's default page wasn't loading the assets right without Jammit
2012-1-10 - 0.2.1
* Added Ember.js * Updated jQuery Mobile to 1.0 * Removed jQuery Templates * Updated Jasmine suite.html template to include the JS you've used
2011-11-10 - 0.2.0
* jQuery 1.7 * jQuery Mobile 1.0rc2 * Added Mustache.js plugin to core * Ensured Skeleton depends on jQuery, removed Google Ajax API from skeleton template
2011-10-09 - 0.1.1
* Changed deployment script template to remove original directory by default
2011-10-08 - 0.1.0
* jQuery Mobile 1.0RC1 * Added -o, --overwrite option, so existing files won't be blown away.
2011-09-21 - 0.0.9
* jQuery 1.6.4 * Added HTMLShiv to index template * Added Google Analytics code to index templates for default and Skeleton * Added default css and js files * Added default coffee and sass files
2011-09-07 - 0.0.8
* Fixed output path for css generated by Jammit * made index creation optional with --skip-index option * made name of "public" folder configurable with -p or --public_dir option
2011-09-07 - 0.0.7
* Added JQuery Mobile support * Refactored output * Fixed issue with assets file extensions * Cleaned up tests
2011-09-03 - 0.0.6
* Libraries can now have dependencies * Plugins can be developed as gems
2011-09-02 - 0.0.5
* Fixed broken guardfile generation * Fixed indentation in generated files
2011-09-02 - 0.0.4
* Index and Rakefile added * Fixed issue with bad libraries
2011-09-01 - 0.0.2