I write fiction in markdown with a horizontal line (---) to denote scene breaks. A lot of the editing software I’ve looked at expects each scene to be its own file. So I wrote a PHP command line script to break apart a markdown file by scene. https://gist.github.com/oddevan/e51c2283c6d27dedd77c7484facf820d