Managing SMF software in GIT

Yesterday, I upgraded three sites running SMF (Simple Machines Forum) software to v2.0RC5, upgrading them from v2.0RC4.  Some of these sites are more than just a simple implementation of the base software.  All of them have some modifications added, one (Melinda’s Backups forum) has a considerable degree of modification, and unlike WordPress, where plugins are pretty much stand alone, relying on well defined hooks in the software to get into the path, modifications in SMF tend to be intrusive.  Despite all the modifications, I upgraded all the sites over just a few hours.

I believe that is because of the approach I have taken to managing the configurations in Git.  In this post I want to explain how I do it.

Continue reading “Managing SMF software in GIT”

Integrating Gitweb output into a WordPress page

One of my known stumbling blocks to converting my site to WordPress was how was I going to manage to incorporate gitweb so that its output appears within the middle of a page, formatted to at least look like a normal page. The problem occurs because gitweb takes over managing the output and writes an html page complete with headers and footer. You are allowed to provide your own site_header.html and site_footer.html files, but these are inserted just after the opening tag and just before the closing tag. There is no way you can add to the header.

One approach to this, and the one I took on my previous version of this site, was to embed gitweb within an <iframe>. Effectively gitweb’s output is sandboxed within the <iframe> context. Unfortunately, despite some javascript trying to detect it, when the quantity of output changed the size of the iframe needed to change and it didn’t seem to do that automatically. I often found the output was chopped off (with a scroll bar provided) even when my full page was nowhere near full screen.

I have taken a different approach this time. In outline I have created a holding page with permalink “/software/” to hold the repository code and then created a special template for my site theme which when called embeds output from gitweb into the page. There are a few tweaks to the header is moved to the correct place and that links within the output are correct.  Down to the detail.

Continue reading “Integrating Gitweb output into a WordPress page”

Having fun with GIT

It was just yesterday morning that a light came on in my head and I understood just what the index file was for in git. It seemed to strip away the fear that I was always not quite sure what I was doing, and allowed my to experiment a bit to see what I could do.

Well I have been playing with the post-update hook. As a result, I can now

It was just yesterday morning that a light came on in my head and I understood just what the index file was for in git. It seemed to strip away the fear that I was always not quite sure what I was doing, and allowed my to experiment a bit to see what I could do.

Well I have been playing with the post-update hook. As a result, I can now

  • push a update from my working machine into a repository embedded within this web site. The arrival of a new update triggers it to check out this new version so that the web server automatically gets the new version to work with.
  • push to any of the public repositories on this machine a new tag (ie release) and it automatically makes a tar ball of the whole code and puts it into the downloads directory

I haven’t (yet) got it automatically deploying new versions of my applications – but I am sure it will not be long:-)

Source Code for recent applications now online

I have just finished putting the my git repositories on-line so that anyone wishing to access the code can do so.

gitweb provides a web interface to show the changes to the code etc, whilst the actual code can be retrieved using git. Use

git clone git://www.chandlerfamily.org.uk/project.git ,

where project.git is one of the projects listed from the web interface.

I have just finished putting the my git repositories on-line so that anyone wishing to access the code can do so.

gitweb provides a web interface to show the changes to the code etc, whilst the actual code can be retrieved using git. Use

git clone git://www.chandlerfamily.org.uk/project.git ,

where project.git is one of the projects listed from the web interface.

Taking the Java Plunge – release 1.0 reached

Well I made it. It was early in the weekend that the code was working, but its taken a couple more days of struggle to get it so I could put it into production. Learning how to get tomcat to authorize the users is hell to debug when it doesn’t seem to do what the book says it should.

Looking back at what I have done surprises me. It was a simple application (just 5 web pages) but the number of separate technologies that I had to learn (or in some cases perfect) were many. Here is a list (on top of Debian Unstable/Stable)

Well I made it. It was early in the weekend that the code was working, but its taken a couple more days of struggle to get it so I could put it into production. Learning how to get tomcat to authorize the users is hell to debug when it doesn’t seem to do what the book says it should.

Looking back at what I have done surprises me. It was a simple application (just 5 web pages) but the number of separate technologies that I had to learn (or in some cases perfect) were many. Here is a list (on top of Debian Unstable/Stable)

  • download and conversion to debian package of sun sdk
  • set up and configuration of Tomcat
  • complilation of jk_mod from source
  • installation and configuration of jk_mod into Apache2
  • download, installation and use of Eclipse with Web Tools (including debugging)
  • download, installation and use of git (and cogito) scm system
  • Java Programming – with special attention having to be paid to the Collections classes
  • download, installation of Tapestry web framework
  • learning all of the Tapestry concepts (basic, forms with translaors and application state objects in particular)
  • download, installation of iBatis database framework
  • learning the use of iBatis concepts (with complex joins and how they populated Java collection classes)
  • set up of postgres access controls so that code and myself (using psql) could create and then access the database
  • SQL for key transactions, and in particular complex joins in order to extract the family relationships from the database
  • set up of jdbc driver for Postgres and configuration in Tomcat so that could access family tree database
  • set up of a datasource realm in Tomcat and a users database in Postgres to provide access controls to application
  • html encoding
  • css encoding
  • javascript and how to use within the Tapestry framework
  • Povray to create the chandlerfamily logo (not in the timeframe of this project – was done earlier)
  • inkscape to draw graphic items
  • gimp to convert graphic items to gif