Deadlines are definitely a double-edged sword. On the one hand, they can be really inconvenient if something takes longer, other priorities pop up, you just feel you need to release a chapter even though you're not really happy with it, etc. On the other hand, in the absence of deadlines, it's easy to put things to the side for a "week" that turns into a month or two.
There are deadlines, and they helped, but a lot of it was about having someone I "owed" something to.
Another thing I did was plot my word count per commit. Once per week I would post it to an internal channel at work and add a sentence or two summarising my week. The most interesting thing is that while my output could fluctuate a lot per week, the overall trend was fairly stable.