Here are a few tricks I use to keep myself motivated.
When editing is sucking the life from my muse, I write little 1,500 word snippets to keep my brain limber. I use the keywords people have used to find my blog to determine the subject. That way, it’s at least something I’m interested in (ex: hairy bear men, oh yeah baby). If you don’t have a blog, you could go on Amazon, find a favorite book, and use a few words that show up in the tag section, or write some fan fiction. I post it here and Literotica as a free read, and I get to remember why I’m writing in the first place—I like it.
Another problem we all run into is motivation. For this, you need a book, or something, that you like to read. No, don’t use Reddit or another such site. It needs to be a story, whether it’s some cheesy vampire smut on Literotica or a wrist-buster from Tor, because Reddit will suck your soul. Now, you need to set a goal and a reward, ex. for every 200 words I write, I get to read one page of this smut on Literotica. Or, for every 10% I edit (I often read things on my Kindle to edit) I get a page of smut (they’re long pages). Basically, your goal is to change a day where you would have been bummed out about being unproductive into a day when you get a little work done. Even if you end up doing more reading than writing, it’s better than none.