howstupid you are absolutely right, diets aren't the way forward.
If you were trying to 'ban' particular foods then I was going to suggest doing exactly the opposite and allowing yourself to eat exactly what you want for a while - on condition that you really, really stop and think if you truly want it and if you decide you do, sit and savour every bit of food you want. Then consider how it affects you afterwards.
Sweet and stodgy carbs are comforting, whilst we are eating them, but they don't leave you feeling great. They are lovely once in a while but you probably know the stuff you should be eating more of.
Would it work for you to try giving yourself just one such thing each day - say, a cake, every day, at whatever time if/when you want it? Having something there and 'allowed' may actually take the attraction away? First have a glass of water when you feel like a snack, then give yourself the option of the cake, or a healthy snack (palmful of almonds, houmous and raw veggies, small full fat greek yoghurt with fruit, half an avocado, a banana), or a hot drink. Make this a habit and hopefully you will end up feeling more energetic and 'up' from the great snacks and be less attracted to the cake, over time you may not even fancy it every day, and then the times you do, you can really enjoy it?
A healthy diet to me means eating what is best for our body 80% of the time but we also need to not label anything as bad, it immediately makes it more alluring - and cake is nice to eat
- food is also about pure pleasure (not to be confused with comfort eating, filling a void of some kind) and social enjoyment so we need to allow for that too in the other 20% of the time, not constantly obsess over what we eat/shouldn't eat/don't eat every day.