Deployment Store

libflitter/utility/DeployStore

exports:  class DeployStore

class DeployStore

Stores and recalls deploy functions. In Flitter, a deploy function is a one-way, non-reversible process that sets up required files and settings for a module. That may be copying controllers and views to the appropriate directories, seeding the database, whatever. This class is usually instantiated at _flit.deployments.

store

type:  Object

Holds the deployment functions by name.

add(String name, function deploy_function)

returns:  undefined

Adds a deploy_function to this.store with the specified name. This function should accept and handle a callback.

deploy(String name, function callback)

returns:  mixed

Runs the deployment from this.store with the given name and passes it the specified callback. This function returns the value of the deployment function.

No Comments
Back to top