     read prompt: promptMsg, silent: true , callback
 
 
-addRemote = (url, devicename, syncpath) ->
+addRemote = (url, devicename, syncPath) ->
     getPassword (err, password) ->
         options =
             url: url



program
    .command('add-remote-cozy <url> <devicename> <syncpath>')
    .description('Configure current device to sync with given cozy')
    .action addRemote


          log.error err


buildFsTree = (devicename, options) ->
    remoteConfig = config.config.remotes[devicename]
    filePath = options.filePath

    # Fetch folders and files only
    db.db.query { map: (doc) ->

        if doc.docType is 'Folder' or doc.docType is 'File'
            emit doc._id, doc

    }, (err, res) ->
        for doc in res.rows
            if not filePath? or filePath is path.join doc.value.path, doc.value.name
                name = path.join remoteConfig.path, doc.value.path, doc.value.name
                if doc.value.docType is 'Folder'
                    # Create folder
