I used to have the same problem and to stop myself I put small drops of hot sauce on my nails and since I disgust spicy things it prevented me from biting them...so I suggest you try the same or if not just put some other thing that you don't like food luck
When I was little my dad always threatened to put my fingers in hot sauce tht way when I bite them it would burn so bad I would learn my lesson and not bite them any more.......he also threatened with dog poop lol he never did and I still bite my nails so I get fake nails lol problem solved