<commit_before>package lime.tools.helpers;


import lime.project.HXProject;


class DeploymentHelper {
	
	
	public static function deploy (project:HXProject, targetFlags:Map <String, String>, targetDirectory:String, targetName:String) {
		
		var name = project.meta.title + " (" + project.meta.version + " build " + project.meta.buildNumber + ") (" + targetName + ").zip";
		var targetPath = PathHelper.combine (targetDirectory, name);
		
		ZipHelper.compress (PathHelper.combine (targetDirectory, "bin"), targetPath);
		
		if (targetFlags.exists ("gdrive")) {
			
			var parent = targetFlags.get ("parent");
			
			if (parent != null && parent != "") {
				
				ProcessHelper.runCommand ("", "drive", [ "upload", "-f", targetPath, "-p", parent ]);
				
			} else {
				
				ProcessHelper.runCommand ("", "drive", [ "upload", "-f", targetPath ]);
				
			}
			<commit_msg>Add "config" option for deployment helper<commit_after>package lime.tools.helpers;


import lime.project.HXProject;


class DeploymentHelper {
	
	
	public static function deploy (project:HXProject, targetFlags:Map <String, String>, targetDirectory:String, targetName:String) {
		
		var name = project.meta.title + " (" + project.meta.version + " build " + project.meta.buildNumber + ") (" + targetName + ").zip";
		var targetPath = PathHelper.combine (targetDirectory, name);
		
		ZipHelper.compress (PathHelper.combine (targetDirectory, "bin"), targetPath);
		
		if (targetFlags.exists ("gdrive")) {
			
			var parent = targetFlags.get ("parent");
			
			var args = ["upload" , "-f" , targetPath];
			
			if (targetFlags.exists("config")) {
			
				args.push("--config");
				args.push(targetFlags.get("config"));
				
			}
			
			if (parent != null && parent != "") {
				
				args.push("-p");
				args.push(parent);
				
			}
			
			ProcessHelper.runCommand("","drive",args);
			
{'fraction_non_alphanumeric': 0.15911542610571736, 'fraction_numerical': 0.0, 'mean_word_length': 3.4806763285024154, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7234163', 'n_tokens_mistral': 677, 'n_tokens_neox': 540, 'n_words': 120}