c2c.recipe.jsconfig is a zc.buildout recipe that generates a javascript configuration file based on key/value pairs in buildout configuration
Python
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
c2c
README.rst
setup.py

README.rst

c2c.recipe.jsconfig

Requirements

Requires zc.buildout.

Installation

c2c.recipe.jsconfig is a zc.buildout recipe which generates a javascript configuration file based on key/value pairs from the buildout configuration.

Installing using easy_install:

$ easy_install c2c.recipe.jsconfig

Manual installation for development:

Download the source code as archive or clone the GIT repository:

git clone http://github.com/camptocamp/c2c.recipe.jsconfig.git

Then run the setup:

cd c2c.recipe.jsconfig
python setup.py develop

Usage in buildout

Create a buildout.cfg file which contains the following:

[buildout]
parts = jsconfig

[jsconfig]
recipe = c2c.recipe.jsconfig
output = path/to/Config.js
namespace = App
key1 = value1
key2 = value2

Then launch the buildout command:

$ buildout

And voilà! Your path/to/Config.js javascript configuration file has been generated successfully.