I can’t breastfeed anymore

I really feel like I am done , I’m so tired, last week after such a rough start baby was finally sleeping well , eating well and generally happy .

Since she turned 5 weeks old last Friday she is cluster feeding from 6pm-12 will sleep from 12-3 then constantly feed from 3-7 :-( she is not happy during the day and won’t nap anymore for longer then 20 mins. she is unhappy unless on the breast

I feel like this is never ending

this will be my last night nursing and will switch to formula in the morning

How do I switch her fully without getting mastitis or other issues?