completed formatting to stdout, including deleted file first character r...

...eplacement and directories with file names
added debug flags, because i used gdb and then didnt take it out of the makefile