package codingpro.werewolves.server;

import java.io.File;
import java.io.IOException;

import lombok.AccessLevel;
import lombok.NoArgsConstructor;

@NoArgsConstructor(access = AccessLevel.PRIVATE)
public final class IOUtils {
	
	/**
	 * @return whether or not the file had to be created AND that was successful
	 */
	public static boolean createFileIfNotExists(String path) {
		File file = new File(path);
		if (!file.exists()) {
			try {
				return file.createNewFile();
			} catch (IOException e) {
				e.printStackTrace();
				return false;
			}
		}
		return false;
	}
	
}

@@ -568,10 +568,216 @@
 e;%0A%09%7D%0A%09%0A
+%09/**%0A%09 * @return whether or not the directory had to be created AND that was successful%0A%09 */%0A%09public static boolean createDirectory(String path) %7B%0A%09%09File file = new File(path);%0A%09%09return file.mkdirs();%0A%09%7D%0A%09%0A
 %7D%0A

Add a function to create directories