package src;

import java.io.IOException;
import java.util.logging.FileHandler;
import java.util.logging.Level;
import java.util.logging.Logger;
import java.util.logging.SimpleFormatter;

public class CrawlLogger {
	
	static private FileHandler fileTxt;
	static private SimpleFormatter formatterTxt;

	static public void setup() throws IOException {

		// Get the global logger to configure it
		Logger logger = Logger.getLogger("");

		logger.setLevel(Level.INFO);
		fileTxt = new FileHandler("logs/crawler.txt");

		// create txt Formatter
		formatterTxt = new SimpleFormatter();
		fileTxt.setFormatter(formatterTxt);
		logger.addHandler(fileTxt);
	}
}

@@ -35,16 +35,130 @@
 eption;%0A
+import java.text.DateFormat;%0Aimport java.text.SimpleDateFormat;%0Aimport java.util.Calendar;%0Aimport java.util.Date;%0A
 import j
@@ -183,24 +183,24 @@
 ileHandler;%0A
-
 import java.
@@ -457,17 +457,152 @@
 ption %7B%0A
+%09%09Calendar cal = Calendar.getInstance();%0A%09%09Date today = cal.getTime();%0A%09%09DateFormat timeFormat = new SimpleDateFormat(%22dd-MM-yyyy%22);%0A%09%09
 %0A
-
 %09%09// Get
@@ -708,16 +708,16 @@
 .INFO);%0A
-
 %09%09fileTx
@@ -749,16 +749,45 @@
 /crawler
+_%22+timeFormat.format(today)+%22
 .txt%22);%0A

Change in the name of the log file