Welcome to SR....unfortunately every single person here can relate to what you are experiencing.
There are lots of great programs to help you with codependency (Al-Anon, Nar-Anon, and CoDA to NA, to name a few). Counseling is also helpful. Reading here on SR will help.
Through working a 12-step program myself (which is likely a similar program to that your gf will experience in rehab) I learned compassion for addicts, I learned how to "say what I mean, mean what I say, and not say it mean". I learned how to detach with love....not with anger. And I learned the language of recovery so that I could relate to my son's experiences in rehab and beyond. It provides us with a common language--not so that I can manage his recovery but so that I can understand that I only control my own.
It was a lot of hard work, but it was worth it. I am worth it.....and so are you.
gentle hugs
ke