Abstinence in common things, or even required things like food is a challenge. Saying you’ll never play is just setting up for failure so when you crack, you play more.
What works for me is to set some non-zero target. That way when I fail, I fail by a percentage instead of an infinite percentage. Pledging zero and playing for an hour is much worse seeming than pledging an hour and playing two. Only a 100% overage.