see the light at the end of the tunnel; have the end in sight
idiomatic expression
Idiomatic expression literally meaning 'the mountains are visible', used when a long task or difficult period is nearing its end and the goal is finally in sight. Often used in contexts of perseverance.