The other thing is audience.
It can help to know who writing your writing for. Pen on Fire began with an audience of one. My student Robin. A lot of you know this story. She would become inspired in class but at home her motivation to write fizzled. She jokingly said, If you came home with me, I know I could write.
I said, I'll write a book for you.
Pen on Fire started with my audience of Robin. Soon it spread to include all of my students and others.
Who are you writing for? It could be yourself. But it has to be someone.