This is the output of a pair programming session with Patrick McElwee and Paxton Hare. During this session we built a simple app for MarkLogic that uses data about legislators and bills.
I cleaned up the dir tree a bit and removed a couple of the unused files like CHANGELOG.mdown to avoid confusion.
This application was generated by the MarkLogic-Node Slush generator, with the following components:
- AngularJS
- Gulp
- node.js: very thin layer, hosting the Angular code and proxying MarkLogic REST API requests
- Roxy Deployer: bootstrap MarkLogic databases, application servers, etc; scaffolding for MarkLogic REST API service extensions
- node.js
- npm: Built-in package manager for node (comes with
node, but check to be sure you have latest version:
npm install -g npm) - gulp: Javascript task automation (
npm install -g gulp) - Bower: A package manager for front-end libraries (
npm install -g bower) - Git - Roxy depends on this version control system
- Ruby - Roxy depends on Ruby in order to run server configuration scripts
./ml local bootstrap
./ml local deploy modules
On Windows, that would be:
ml.bat local bootstrap
ml.bat local deploy modules
Install additional dependencies using the bower package manager:
bower install
If you want to upload a dictionary for spell-suggestions:
./ml local deploy content
On Windows:
ml.bat local deploy content
Edit ./local.json to set your desired ports
gulp serve-local # this will watch the .less file for changes, compile them to .css, and run the node server
To load the Legislator data simply issue this command:
./ml local load_legislators
Or on Windows:
ml.bat local load_legislators
To load the bills simply issue this command:
./ml local load_bills
Or on Windows:
ml.bat local load_bills