I sort of built a routine around DD when she started sleeping, followed her cues. Until 8 weeks there was no order to anything, she just slept on either me or boyfriend, and we co-slept. It was lovely and we actually got quite a lot of sleep. I'm really glad I didn't stress about a routine at that time.
Around 6 weeks she started sleeping long stretches so we would sometimes put her in her moses basket, in the main room with us in the evening and then in our bedroom at night.
Around 4 months I think it was obvious she could get excited and overstimulated by things around her, so we started a "bedtime routine" to take her away from it. It was just a brief thing then, a feed and a cuddle in a quieter room and a rock to sleep. It's more extended nowadays (specific time, low lights, books, cup of water, change, breastfeed, cuddles till she sleeps).
We moved her into her own room at 8 months and the routine's been quite strict since then. I ensure she gets good naps (though they are often in the sling, pushchair, my arms - whatever, not fussed).
So I did things gently and slowly and she's always been a happy baby (and a good sleeper other than during developmental spurts - but I think babies just vary on that front).
She is now 10 months old, she still can't self settle at all, and she often sleeps 6.30-6.30 with one brief bf and no other wakings. Go figure.
So my experience has been the "bad habits" have just been a nice way to keep everyone happy and meet her needs and my own, and they have disappeared naturally with time, but obviously babies vary.