I don't get discouraged from writing docs because nobody reads them. I'll read them.
But I do experience another similar self-reinforcing problem:
If other people don't read or update my docs, the docs begin to lie.
It is inevitable because some competent programmers deliberately don’t comment their code, read comments, or delete other people’s comments when they are stale.