 class exports.Manifest
 
 
+    # Attempt to download application NPM manifest from three different
+    # location (location selection is based on manifest information):
+    #
+    # * NPM registry
+    # * Gitlab repository
+    # * Github repository
     download: (app, callback) ->
 
         if app.package?

                callback null, {}

        else if app.git?
            providerName = app.git.match /(github\.com|gitlab\.cozycloud\.cc)/
            if not providerName?
                logger.error "Unknown provider '#{app.git}'"

            callback null, {}


    # Download the manifest from the NPM registry. This manifest has many
    # information (it includes history). So we extract the lastest version
    # of the application manifest.
    downloadFromNpm: (packageName, callback) ->
        client = request.createClient "https://registry.npmjs.org/"
        client.get packageName, (err, res, data) ->
