Simple/Static Content Management System (C) Richard Whitty September 2008 cs6rlw@csc.liv.ac.uk ----------- This is a content management system written to not require a database or server-side scripting. It is written in the bourne again shell scripting language, just because it was quick and easy. There are three main modules: * Blog * Projects * Links It supports user-defined stylesheets, and is capable of producing standard XHTML (though part of this is up to the user). This is aimed at people who could quite easily produce their own site to do the same thing, but just want to make things a bit easier. Project Directories ------------------- Each project is given a subdirectory within $PROJECT_DIRECTORY. The following plain text files are used to provide information about the project. long_name -- the name of the project to be displayed. (can contain spaces etc) short_name -- the name of the project for purposes of links and directory structure. Suggested to be a single alphanumeric string. brief_description -- tag line, or first paragraph of description. Should be able to stand on it's own. long_description -- the full description of the project. (optional) link_paper -- url of link to paper relative to the webroot, (optional) link_source -- a link to the source tarball or file (optional) image_url -- the URL of the screenshot or image. (optional) These are rendered to the projects.html page, and also the sidebar. Blog ---- Each post gets a subdirectory in the $BLOGDIR directory. Each of those contains the following files: name -- The title of the post link -- if the title should act as a link to some other site, then this file contains the URL of the link. (optional) content -- the contents of the post. Front page ---------- these files live in the personal/ directory: aboutme -- the text to put on the main page. imageurl -- a picture to display next to the title (optional) Links ----- The site can display a number of links in the sidebar. Each gets a subdirectory in 'links' containing the following files: name -- The name of the link (or the alt text for the image) link -- the URL to link to. icon -- image to display for the link, the name is then used as the alt/title text. (optional) Additional notes ---------------- The text files are run through the paragraphing function. This means that all the text will be enclosed in
tags. If you need to include other things, such as lists or preformatted segments, then it will not generate valid XHTML (but will still work in all the browsers I've tried). For this purpose some of the files can be suffixed with _raw, in which case the contents of the file will simply be dumped into the relevant part of the page, without being run through the paragrapher. The files this applies to are: blog: content (so it becomes content_raw) projects: brief_description (brief_description_raw), long_description (long_description_raw) main page: aboutme (aboutme_raw). If the raw file exists, then that will take precedence over the non-suffixed file. Configuration variables ----------------------- There are a number of configuration variables you should edit in the script if you intend to use this for your own website: DESTINATION -- the path to sync to as gets passed to scp. PROJECT_DIRECTORY -- the directory containing the project subdirectories. BLOGDIR -- the directory containing the blog post subdirectories. CSS_FILE -- The stylesheet to use. BLOG_SHOW_POSTS -- the number of blog posts to show on the main blog page, any others are relegated to the archives. LINKDIR -- the directory containing the link definitions. FIRST_NAME -- first name of the site's owner. LAST_NAME -- last name of the site's owner. EMAIL_ADDRESS -- contact email address for the site. SITE_TITLE -- the title of the site.