There's some information about Twine that can be a starting point, but you're going to need to find a format (Chapbook works well for me, link is also there) to use, if you want to publish with this.
It took me a bit to figure out how to get it working, but I now have it working quite well, and have a story of ~2500 words, that will be expanded at least somewhat.