First Entry, (about this blog)

Wow! Well, nearly 10 days ago, while listening to a late night radio show on CJOB, I began to think about the feasibility (spelling?) of closed biospheres in modern days survivalism.

The US was recommending people buy up duct-tape and plastic to seal off their windows and doors as a preventitive measure in the case of a bio-based attack. Now this got me to thinking -- .oO(That's just dumb, if they're sealed off, they'll run out of air to breathe). So I started postulating just what would be required for a closed biosphere to be successful. Now, I know that there was the "Biosphere 2" project a while back, but it mostly failed. On that note, I decided that rather that implementing the whole system, I'd work on implementing parts first, and then if I ever had a Ph. D. in Engineering, I'd actually implement the closed system in its entirety.

Now, as a direct repercussion of this, I began postulating HTML as a document format, since you can have many files linked to each other with little difficulty compared to word processer documents. (This also somewhat resulted from my reliance on linux based programs, of which there is no MS Word caliber word processer... yet.)

  • Revision 1: A template html file with really nothing special about it -- might as well have been rewriting the file each time I made a new document -- the overhead was too high.
  • Revision 2: Another template html file, but this time I moved most of the formatting into a .css file. This had the great advantage over the previous revision such that when writing a new file, one only really had to worry about the content, and less about the formatting...
  • Revision 3: Well, I wasn't satisfied -- I didn't want to have to touch the formatting inside these files -- I just wanted to be able to write what I wanted and have it done -- more like a word processer (again). So I abstracted all of the formatting and put them in the print statements of a python script (as well as still using my css file). I spent a little time making things look half decent; the tabbed entries you see now are a result of this work. Any entries I wanted to add went into a .blog file in the directory with the scripts, and then I had to manually add a reference to that .blog file inside the script -- and for old entries, I had to manually move them into another (nearly identical) script, and so on. Once again, I thought .oO(This is too much overhead!). The straw that broke the camel's back, so to speak, was the fact that these pages wouldn't render properly in IE - but were fine in mozilla, konqueror, opera, etc.... too bad 90% of websurfers use IE...
  • Revision 4: Redid the CSS file, keeping what was good and what wasn't, I rewrote such that all browsers (except perhaps netscape 4x) will render it. I removed the referenced to the .blog files from the scripts, and made them more generic - such that I could say "./make_html.py links.spec links.html" and all of the links would be only have to be listed in links.spec to end up in links.html. This is all good, except that I needed shell access to the computer in order to update anything. Once again -- too much overhead work.
  • Revision 5: Up until this point I didn't need a webserver -- I was just reading and changing the {.py|.css|.html|.spec} files locally, but I figured I could make them a little more dynamic. So, I installed mod_python (with some difficulty, had to upgrade my apache server, etc). I wrote from scratch my first dynamic content scripts, which were quite poorly done, and rendered without any formatting in the browser. I could now add entries using a web-form, and have the time-stamps automagically generated and such. All very well and good -- except that the code was so bad, and it was so ugly that it soon required rewrites in portions that broke while fixing a loop in another file off someplace. Also, all of the admin functions were in one file, so this file was getting quite large... 650 lines of code large, and growing. Much too big for one file. I also made the mistake of programming it in an overly linear fashion, as I hadn't yet figured out how to write/call/use functions in python. Also, for each subdir on the system, I was keeping an individual copy of all the scripts, requiring a 'Propigate Changes' form each time I changed anything in the slightest.
  • Revision 6: This revision -- the one you're looking at now! I fixed all of that. The admin scripts now require passwords, and they're saved to disc encrypted! And yes, I did say scripts -- everything is now very modular -- no more propigating changes required, and managing the different dirs on the system is a breeze. I can add, edit, remove content with little difficulty, and the code is clean. I didn't just 'hack' this revision, I designed it, and although it's far from complete (I want to add more functionalities) the framework seems sound enough. I could modularize the code a bit more yet, but nothing that would require a complete rewrite to do. It already can do some dynamic layout, etc. (eg, I can choose to show/hide elements, or put the menu on the top, left or right....) and does auto-paging when more than N elements (and N is configurable).

This the progression from being a simple .html template into a fully capable news-style blog is nearly complete. I'll likely spend a few weeks polishing, shining, breaking and fixing, but I like the framework that's resulted.

I'm considering adding(/completing) the following sections: links (for misc links, although the side menus can do this to an extent); about (for personal info, resume, etc); comments (the ability for others to tag existing blogs with comments of their own); projects (a project manager/updater, etc...); images (an image gallery, with images able to uploaded through the admin menu, auto-thumbnail generation, etc); dynamic css creation (allow overriding of the default blog.css file with a custom one); hit-counter (count the number of times page X has been accessed); search functionality (this can inherit from the entries index generation, but I haven't really thought it out yet) and much more -- all of which would be configurable without too much fuss...

Whatever happened to the biospheres?!

Oh, I'm still thinking about it -- programming has taken most of my time in the last 10 days however. Once I have the last of the bugs ironed out here, look for some entries (news style) regarding them. Also, my main motivation to complete the projects sub-section stems from my pondering on the biosphere, rex, kde-os, and more...."

Until next time, be safe...