Lawyers, birth certificates, and custody confusion

Mommy February
My ex and I were together for 4 years and I found out the week before I found out I was pregnant that he was cheating on me. So I kicked him out and he tried to make things work with me and be back together. A few days later a girl that has always threatened me and glares at me put up that they were in a relationship. So I said we were done, as much as I didn't want to. When I found out I was expecting with him and thought he deserved to know. So I told him. And he is so excited and said he doesn't want his new gf having any involvement, but I have mixed feelings and think she will convince him to take me to court and try and get full custody. I just do not know what to do with custody agreement offers to him and if I even put his name on the birth certificate because I have friends who have had horrible experiences. I want to cooperate cause I'm a nice person, sometimes too nice. But I don't want my kid to end up being passed around or if my ex gets back into drugs like coke or being with random girls , I just don't think that is a good situation with a kid. I hope he smartens the the hell up. I want my kid to have his or her dad there. But what is everyone's take on what to do with custody and signing the birth certificate? I've been told if I don't put his name on the birth certificate won't have troubles. But at the same time if I make it look like I wanted him more than involved and put his name on the birth certificate , if he were to ever take me to court the court system would be more understanding with me cause I tried to have him involved. But if i don't it looks like I tried to keep him out of my kids life. I'm so confused???