crb3's writer stuff |
|
|
This is a collection of small interacting tools, all of them Perl scripts,
which I devised to help me gain control of my own personal writing process.
You might find one, several or all of them useful; your mileage will most
definitely vary. Some of these tools have seen mention elsewhere on this site. The links from this page go to syntax-highlighted html pages of Perl, from which you can download a gzipped straight-text version of the script (with Linux line-endings).
tburstertburster tears a body of text apart, disassembling it into a cluster of small enumerated files on cut-edges signaled by the tag '#extract' (or, as an option, '#CH', which is a convenient chapter-flag). It was written for one task: to break up a file containing a large, unwieldy, incomplete work of fiction into a cluster of much smaller files (with enumerated names) which are easier to shuffle around. It also turned out to work quite nicely to slice up a fully-converged work into chapters. tpptpp, an intentionally dirt-simple text preprocessor, assembles a work of fiction together from a collection of small text files, using an include-list as the spine, text-macros to build scene-breaks, chapters and the rest of the structural scaffolding, and conditional inclusion so that rejected (or rating-inappropriate) chunks of text are simply not included in a given version's output. Why? Everybody's got their own text preprocessor, seems like. They all start out simple and small and then get complex and powerful, and the power comes at a price: greater restrictions on what you can do with the tool, and greater bulk in the tool itself, because all that complexity is loaded at runtime whether you use it or not. As the tool grows, you eventually find that you've created yet another little language to memorize (or not so little: look at PHP, which was a text preprocessor written in Perl when it was born, but by now might as well stand for Perl-but-Hold-the-Punctuation). This one is staying small and simple, so you can see sooner whether you can get it to do what you want without tripping over the restrictions imposed by its mechanisms. The only bulk is Perl, and that's not a high price. t2ht2h is a text-to-html converter which understands the fanfic convention of underbars as italic-toggles and asterisks as bold-toggles. It has an internal template into which it can paste its html output, or you can specify a template which is designed for your story and your site. t2efict2efic is a later, looser rewrite of t2h. It was written to produce html which can be pasted into a website's online editor. Where t2h, by default, tries to be picky about where it sees underbars and asterisks as typographic toggles, allowing for the possibility that the text it's processing might be technical prose where those characters have textual meanings, t2efic is ruthless. I've tweaked it to where I'm happy with the html it produces for eFic and Drupal sites. On a KDE/Linux system, I open the emitted html file with kedit, click Select-All, click Copy, and then I'm ready to mouse-paste the whole chapter/story into the site's editing window; typically I then have very little cleaning-up to do on it before I'm ready to go from Preview to Submit. tindexertindexer generates an index page for a subdirectory containing chaptered html files. I'm still playing with it, sweetening it for my purposes, but here it is because it's already part of my build process, which involves pushing a raw story to HTML so I can give my prose 'fresh eyes' scrutiny using a browser. I catch a lot of lumpy language and spelling/typo/grammar mistakes that way. The more completely I can shift gears mentally from generating the story to reading the story, the more critical I can be of how things work within the story, so having the incomplete work presented to me in a polished manner matters. Once the story's done, the same index page can go on a public-facing server, but it's already been quite useful to me by then. tindexer is part of every build because I move things around as I work, trying to arrange a good dramatic flow and keep chapters from becoming unwieldy, so chapter counts and boundaries are subject to change.
txgraf
txgifgraf
tcams
A character with a camera is a major character, so you'll want to pay attention to how their 'on-screen' time is handled over the length of the (novel-length) story. To manage that, I put a #cam=xx,yy tag at the beginning of each burst-out little file, noting what cameras are used within. Then tcams generates a graph of some or all of the cameras, in percentage of chapter size, across all the chapters. tcams depends on the CPAN Chart and GD packages. I'm still exploring making use of it and this analysis technique for fiction, but so far it does generate a helpful overview.
| ||||||||