Psalm 51:17 "My sacrifice, O God, is a broken spirit; a broken and contrite heart you, God, will not despise."
Contracts can be a beneficial tool to help you commit to living a more holy life. Just remember the rule is not as important as the relationship. The act of quitting, moderating, and enriching should never become more important than the desire to follow and seek after the Lord. YOUR SALVATION DOES NOT DEPEND ON YOUR HOLINESS, BUT IT RESTS FIRMLY ON THE BLOOD OF OUR SAVIOR.
You might be sure your heart is right before the Lord when you enter into a commitment, yet at the same time you cannot fulfill it. You may not feel strengthened as soon as you sign your contract. You may not perfectly fulfill your promise. Don't become discouraged. Just begin anew as soon as you are able. If you become so frustrated that you want to tear up the contract, just put it away in a drawer until you have prayed over it for awhile.
God's not mad at you for being imperfect. He created you to depend on Him, and that takes time. Enjoy the time you spend with the Lord each day and sooner or later, He will bless you with the ability to resist the flesh, live a disciplined life, and be a coworker with Christ. I'm praying for your success in these areas! God bless!