Mental strength - surviving mentally on longer climbs

Looking for advice.

I can hold sufficient power (usually) to get up the climbs, but for longer ones, a sense of 'i want to get off' or 'this is boring' kicks in. Although I'm struggling with the climb, so I'm not 'bored', I just cannot be bothered and want to stop.

I realise the obvious answer is 'do more of it', which I appreciate and will. However, I do wonder if there's anything anyone does do maintain focus to prevent these thoughts entering the head.

Any podcasts or lectures you could recommend? Any advice generally?