It is VERY difficult for work to provide your true meaning in life. 95% of software is personal preference. Most code will be thrown away when priorities change. Do the best you can and learn when you can. Management will always make poor decisions and are usually not interested in unfortunate truths. Work should only be what is required to gain money to pay for living.
The change has to be in you. Finding a hobby or raison dêtre makes waking up easy. Having something to look forward to is key. Once work is something to just finish changes everything. Respect your "you" time and turn off all notifications from work you can. Find something that does bring you joy and do that until it doesn't. Then search for a new thing. Too often we expect a brutal competitive job to also provide us peace and tranquility. They are best kept separated in my experience.