public static void execFolder(File baseDir, File target, File templateDir, File pluginDir, Map<String, Object> parameters) throws ScriptException, IOException, ScriptEngineNotFoundException {
		if (!target.exists()) {
			throw new FileNotFoundException(target.getAbsolutePath());
		}
		File[] childlen = target.listFiles();
		List<File> sortedList = new ArrayList<File>();
		for (File file : childlen) {
			sortedList.add(file);
		}
		Collections.sort(sortedList, new Comparator<File>() {
			@Override
			public int compare(File f1, File f2) {
				if (f1.isDirectory()) {
					if (f2.isDirectory()) {
						return f1.compareTo(f2);
					} else {
						return 1;
					}
				} else {
					if (f2.isDirectory()) {
						return -1;
					} else {
						return f1.compareTo(f2);
					}
				}
			}
		});
		for (File file : sortedList) {
			if (file.isDirectory()) {
				execFolder(baseDir, file, templateDir, pluginDir, parameters);
			} else if (file.isFile()) {
				String canonical = picupCanonical(baseDir, file);
				execScript(baseDir, canonical, templateDir, pluginDir, parameters);
			}
		}
	}