After numerous attempts to quit smoking, I found a small self-help book - can't remember what it was called or where it came from - but the approach it took was to personalize the urge to smoke, by inventing a character called the The Addict. It basically went "Inside you is a person called The Addict, who is constantly trying to get you to smoke. You've finished a job? The Addict suggests you have a smoke - you deserve it. Having a drink? Here comes The Addict..." etc etc. Maybe I was deflecting my own weakness and being able to blame someone else who did not have my best interests at heart, but it worked for me. I also stayed away from bars for the first few weeks (back in the day when you could have a smoke with your beer). That was >20 years ago, and while I occasionally get nostalgic about the whiff of a freshly-lit cigarette, I have no urge to light up.