protected function prepareExcludes()
	{
		$this->log('prepareExcludes', LOG_DEBUG);

		chdir($this->basedir);

		$exclude_param = '';

		if (count($this->rsync_excludes) > 0)
		{
			foreach ($this->rsync_excludes as $exclude)
			{
				if (!file_exists($exclude))
				{
					throw new DeployException('Rsync exclude file not found: '. $exclude);
				}

				$exclude_param .= '--exclude-from='. escapeshellarg($exclude) .' ';
			}
		}

		if (!empty($this->data_dirs))
		{
			foreach ($this->data_dirs as $data_dir)
			{
				$exclude_param .= '--exclude '. escapeshellarg("/$data_dir") .' ';
			}
		}

		return $exclude_param;
	}