Communicate with certainty
and your Voice will be heard.

Category Archives: Software


theMechanism has been using Subversion for just over a month now. The following is a quick guide to installing and working with Apache, Subversion and SvnX on Mac OS X:

Apache, Subversion and SvnX on Mac OS X

Apache is the local web server (used to view and test files in the working copy), Subversion is the version control software and SvnX is a GUI-client for Subversion.

Before we can use Apache, Subversion and SvnX, we need to check:

  1. Is Apache running?
  2. Is Subversion installed?
  3. Is SvnX installed?

Apache

To test Apache, fire up the browser of your choice and enter

1
http://localhost/

into the address bar. If you do not see an "Unable to connect," "Can’t connect to server," or "Error! Connection closed by remote server" screen, Apache is running.

If it is not running, open System Preferences. Under "Internet & Network," choose "Sharing." Make sure "Web Sharing" is checked ("Personal Web Sharing" in Tiger).

Mac OS X Internet & Network Sharing window screen grab

Note that

1
localhost

is pointed at

1
/Library/WebServer/Documents/

.

Subversion

To see if Subversion is installed, launch Terminal (Applications | Utilities | Terminal). At the prompt, type:

1
svn --version

Some information on the version and build should appear. If not, Subversion is not installed.

Mac OS X Terminal screen grab showing results of running svn --version.

If Subversion is not installed, download and install the latest version from http://www.collab.net/downloads/community/

SvnX

To see if SvnX is installed, check for svnX.app in the Applications directory.

If it is not there, download and install the latest version from
http://www.lachoseinteractive.net/en/community/subversion/svnx/download/

Working with Subversion via SvnX

Standard Subversion workflow:

  1. Check out a working copy
  2. Make edits to the working copy
  3. Commit the edits to the repository

Checking out a repository

Screen grab of SvnX's Repositories window.

Launch SvnX and set the focus on the "Repositories" window.

Click the "+" button to add a repository.

  • Change the name to something descriptive.
  • Enter the path to the repository.
  • If required, enter your user name and password for the repository.

Once a repository has been added, it will appear in the top half of SvnX's Repositories window. Double-click on the repository to open it:

An open repository in SvnX.

Click the "svn checkout" button at the top of the window and navigate to a directory below

1
/Library/WebServer/Documents

. Click the open button and SvnX will download the repository to your local machine.

Close the current window and the SvnX "Repositories" window.

The Working Copy

Set the focus on the SvnX "Working Copies" window. Note that SvnX has added a working copy after check out. Change the name to match the descriptive name in the previous step.

Screen grab of the SvnX Working Copies window.

Double-click on the working copy in the top half of the "Working Copies" window. The main thing to be aware of here is the "Update" button. Click this to refresh your local working copy with any changes made to the repository by any other team member.

In Finder, navigate to the working copy, open index.html in your favorite HTML editor, make some small change and save index.html.

Switch back to the active working copy window and click the "Refresh" button at the top of the window. You’ll see that index.html is added with a "M" (modified).

Screen grab of an open working copy in SvnX.

If you're happy with the change and have previewed it to make sure everything is working, press the "Commit" button on the right side of the screen.

Add a meaningful commit message and press commit.

Version control principles

  1. Update often!
    1. Keep your working copy up-to-date by updating often.
  2. Commit early and often!
    1. Early and often means make atomic changes. Change one thing, test and then commit with comments.
  3. Never commit broken code!
  4. Jeffrey Barke is senior developer and information architect at theMechanism, a multimedia firm with offices in New York, London and Durban, South Africa.

Adhesive 3.4.0 has been released! This latest version of the WordPress "sticky" post plugin is compatible with WordPress 2.6.5 and no longer breaks WordPress's native paging functionality.

Jeffrey Barke is senior developer and information architect at theMechanism, a multimedia firm with offices in New York, London and Durban, South Africa.

Version 2.6 "Tyner," named for jazz pianist McCoy Tyner, contains a number of new features that make WordPress a more powerful CMS: you can now track changes to every post and page and easily post from wherever you are on the web, plus there are dozens of incremental improvements to the features introduced in version 2.5.

Read about all the updates at the WordPress blog and download 2.6 here.

As Jan Odvarko notes, "I was surprised how many Firebug extensions … exist out there." Check out his list of 12 extensions at http://www.softwareishard.com/blog/firebug/list-of-firebug-extensions/. All extensions include a brief summary of what they do, a screen capture and a link to the download page.

Two that I use are YSlow and Odvarko's own Firecookie.. YSlow analyzes Web pages and determines why they're slow based on Yahoo's rules for high performance web sites. Firecookie makes it possible to view and manage cookies within the familiar Firebug UI.

Jeffrey Barke is senior developer and information architect at theMechanism, a multimedia firm with offices in New York, London and Durban, South Africa.

While at the ISOC-NY monthly meeting last night, I learned about a cool project of theirs: ISXubuntu. ISXubuntu will be a Linux live CD, based on Ubuntu Linux, which has been optimized for security and privacy while online. The global Internet Society has provided a grant to cover development costs and so that CDs may be distributed free of charge.

ISXubuntu will feature anonymous Web browsing using Tor, ad blocking with Privoxy, encrypted email with Enigmail, encrypted instant messaging with OTR and the ability to store a personal home directory and other configuration settings on an encrypted USB flash drive.

Volunteers are needed for this project, so if you're interested, get involved: http://isoc-ny.org/isxubuntu

Jeffrey Barke is senior developer and information architect at theMechanism, a multimedia firm with offices in New York, London and Durban, South Africa.

Just got finished with my first WordPress 2.5 upgrade and I'm happy to report that everything (except a !@%$#%@ spotty internet connection which made the process take at least three times at long!) went smoothly. Contrary to my expectation, none of the plugins broke!

The admin interface certainly is different—it's better, but still odd after so many years with the old one. However, I love the new one click plugin auto-upgrade feature. It downloaded, unzipped, and installed the latest version of Akismet without any problems.

Update 2008-04-06: I also like the new "modal" window approach to file upload. While the old file upload tab on the "Write Page" page was definitely usable thanks to an

1
<iframe>

and JavaScript, the interface was still a bit clunky. The new UI is definitely faster and slicker.

Update 2008-04-07: While doing another upgrade (from 2.0.9 to 2.5) I broke my first plugin: Category Visibility. However, since I'm not sure what version (other than the 2.0 series) it was last compatible with, this may not be a 2.5 issue.

Update 2008-04-07: It appears that

1
query_posts()

(or at least the way I've always used it!) is broken in 2.5. More on this to follow…

Update 2008-04-09:

1
query_posts()

is not broken, but the Adhesive plugin is.

Jeffrey Barke is senior developer and information architect at theMechanism, a maxi-media firm in New York City and London.

If you're using the WordTube extension for WordPress , haven't been hacked yet, and haven't heard about the remote code execution vulnerability, then you're very lucky and should read on.

The Problem

The following critical problem affects every version of WordTube prior to 1.44. From Secunia:

M.Hasran Addahroni has reported a vulnerability in the wordTube plugin for WordPress, which can be exploited by malicious people to disclose sensitive information or to compromise a vulnerable system.

Input passed to the "wpPATH" parameter in wordtube-button.php is not properly verified before being used to include files. This can be exploited to include arbitrary files from local or external resources.

Solution

Upgrade to version 1.44 immediately!

Jeffrey Barke is senior developer and information architect at theMechanism, a maxi-media firm in New York City and London.

Adhesive is a WordPress plugin that allows one to easily mark certain posts as "sticky." Sticky posts always appear at the top of the page when WordPress displays several posts, but if more than one post is sticky, the post with the latest post time will appear topmost.

Adhesive was originally written by Owen Winkler and available at http://www.redalt.com/downloads/. Unfortunately, it is no longer available, and the last version by Owen doesn't play well with WordPress 2.1. So I fixed it and am making Adhesive available here.

Installation/Usage

Simply follow the download link below, unzip the download and drop it into your WordPress plugins directory. Then activate Adhesive via the plugin administration panel.

To make a post sticky, edit it and either check the "Sticky" checkbox located in the right column below "Keep this post private" or in "Custom Fields" add key

1
sticky

with a value of

1
1

.

Please note that if you deactivate Adhesive, all posts marked sticky will revert back to regular status. To upgrade this plugin and preserve posts' sticky status, just overwrite the old Adhesive files with the new ones.

Download Adhesive

Adhesive 3.4.0 for WordPress 2.6.5. Last updated 29 November 2008. Release notes.

Adhesive has been tested under WordPress 2.6.5 in Firefox 3.0.4, Google Chrome 0.4.154.25, Internet Explorer 7, Opera 9.62 and Safari 3.2.1 running on Windows Vista. If something isn't working right, please leave a comment.

Jeffrey Barke is senior developer and information architect at theMechanism – New York, a multimedia firm with offices in New York, London and Durban, South Africa.