split main.c in net.c and others
added gitignore