NietShell

<earlier> ^| upward |^ <later>


Refresh the Page

As noted previously, these pages came to you from nearlyfreespeech's servers rather than a computer in my bedroom. I'm down with that. Creating this site is plenty of work without the added responsibility of managing the server's changing IP or updating the firewall's IP blacklist. The next iteration may involve my own infrastructure, but that future is plenty far.

My current struggle, instead, involves updating the layout of the site or the navigation links at left. If I permanantly settled on this layout, I could restrict myself to just updating totally new pages. Unfortunately, the perfect format has eluded me in the iterations I've undertaken so far. This has meant uploading every single html file of the site with every improvement. Today, that means 33 pages.

But, as I import the 74 or so articles I wrote when using my Sangfreud blog, this will become wildly unmanagable. My thoughts occasionally turn to using a Content Management System. Perhaps you've used Wordpress? It is a CMS specifically geared to producing blogs. However, it also does so by running on the server and updating the database that stores all the files dynamically. Specifically, the server builds some parts of the pages as it handles your browser's request. To do so (by upgrading to a php account on nfs) would cost me extra, which I can't justify.

Of course, as an aspiring software developer, I should leap at the chance to serve arbitrary pages that can self animate or display tweets copied from my feed that very moment. Changing all these pages by hand certainly flies in the face of my impulse to automation. To be fair, I've been chipping away at a python script to deposit the aforementioned Sangfreud posts into this site's template. (WP exports as an xml file.) I used JainBasil's html generator to turn them into naked html files. 100 times better, but - given the number of conversions - a daunting task.

So, I acknowledge that I would like a solution. But, I realized today that it would behoove me to express what I'm looking for rather than despise tedium look at AlternativeTo for Drupal cringe gird loins for more tedium. An imposed wysiwyg editor would be a showstopper. I imported some files into Sangfreud from MS Word. I cringe at the HR Giger-esque html it produced. Markdown isn't interesting either (though I know Markdown parsers are easier to write than an html validator). I have content squared away and <a href=" is the longest tag I regularly type.

No. The system I envision is closer to the functionality of an IDE, specifically the refactoring feature. When creating an interlaced seried of Java objects, it can be tedious or even dangerous to rename a particular class across several or many files. There is lots of space for forgetting a spot or mistyping the new name. So, most IDEs offer a refactoring tool. It works like a search & replace box that edits across all the files within the project.

That would have helped a lot when I realized that naming the hub pages in various folders whatever I wanted was less optimal than calling them index. At this point though, my edits are likely to be within files rather than incorrect names. Glancing over intelliJ's ide, it seems to support renaming at the attribute level. But, I suspect that wouldn't have helped me in the last update when, amoung other changes, "<previous> !|up|! <subsequent>" became "<earlier> ^| upward |^ <later>". No. The system would probably encourage me to wrap elements like that in a span and give it an id or class. That way it could identify those sections across the project without needing file tags for blogs or whatever.

My mild concern is that doing so would bloat up these web files with spans for identification rather than css or another direct purpose. So there are more spans. The productivity benefits would be much higher than a pinch of unreadability. Actually, this would only be around layout elements rather than dribbled in with the content. Would it though? I don't trust it, but acknowledge that is a non sequiteur. The more pertinant response is that larger files impact my memory usage.

In times past, I'd have been unaware of content size as an issue. Were I to have switched to tumbler or stayed on blogger, the subsidy is invisible. But here I've assumed financial responsibility for my words. Granted, in the three months since I opened the site, I've only been charged two dollars and eighteen cents in total. As I grow the site, I will probably end up spending ten dollars for the whole year. That price matches the only real competitor, lithium hosting. In that sense, I'd have traded a vast unused bandwidth/memory allocation for ssh access & practice. (Which on LH is five dollars extra & requires "government photo id".) In nfs' favor, dynamic sites ($3.65/year) can run cgi-scripts of a great many languages rather than just php.

-+-+-

But, looking over my account, transfers have cost me more than memory, which has been cheaper than the DNS resolution. So the above is a silly quibble. No, best to put a cms on trial and decide thereby. Since yesterday, I've looked over a fair number of cms and found them heavy or focused on divergent use cases. I suspect mine is rather distinct. I'm not building a company site, nor a webapp that will churn out graphs based on somebody's api. As above, I really just want to fool with the layout across all or some files across the heirarchy. I can handle the content. There seem to be plenty of template factories, but I can't tell if they only poop out pages or change legacy pages when users update the base template.

Really, though, my options break into three groups. A) All encompasing frameworks, like Drupal. It seems I could probably get just what I want either normally or as part of a cms 'distribution'. However, finding the rough diamond to polish will mean wading through a lot of dross. B) Free templates. Nonstarter. I might as well go back to using blogger or commit to this layout until I close the site. C) Wade through dross on github or bitbucket, looking for a developer who had the same need I do and released his'o'er work. I have yet to turn up the needle, but may keep looking.

Admittedly, this post has largely been a meditation to draw out my needs than a concerted search for a prebuilt solution. I might end up doing it myself. Specifically, last month I had been thinking of revisiting a deviantart file renamer I made some time ago. In that case, (in C++) I had a script look at every filename in a folder and directly check/apply the transformation I intended.

That's cool until they change their scheme even a little. So, I wanted to update it as an opportunity to create a system that would accept plugins. The means I settled on, assuming java, would be to transcode several pushdown automaton grammers into simple classes (ie a big else if field) that would transform the filename just the way you want it. I could use regex, but not for everything. For example, a regex simply can't be built to identify a string that has twice as many A as B, in arbitrary order. But a pda could. Mind, I don't expect that anyone would use a file renamer that way, but flights of fancy needn't be bound that way.

To close, when I build the renamer, it could effortlessly be modified to muck up strings within files rather than filenames. Constructing the grammers would not be effortless, but looking within files is. Touching every file in every subfolder is. And yet, is that the best way to proceed? I'm not saying Drupal and similars have no value, so much as that they bring a lot of irrelevant functionality to the table that I will have to bend to work just as I need. The same would be true of the renamer, instead because of minimalism. The distinction lies with the likelihood of encountering either in future work venues.

In the short term, this means I will download either a copy of Drupal (which shouldn't force me in a particular way) or some Mustache based lite cms (which should be an amenable template generator). Oops, I meant to say I will continue to do this by hand and experiment with both before deciding which is likely to fit my needs best.

© Nicholas Prado <earlier> ^| upward |^ <later> category: Hosting; Interpreted Glyphs