Handy Linux Commands

This post is simply a personal reference of useful Linux commands. Feel free to comment and suggest new ones to add to the list.

VSFTP

  1. Add a user - useradd <username>
  2. Set a password - passwd <username>
  3. Prevent user from login - usermod -s /sbin/nologin <username>
  4. Change user's home directory - usermod -d <path to directory> <username>
Posted in General | Leave a comment

Git basics: Part 1

This post is intended to serve as a reference for me as I begin my journey into Git.

First set up some basic settings on your Git install:

$ git config --global user.name "Donnie"
$ git config --global user.email "myemail@mydomain.com"

Creating a new repository:

From within the working directory of the project run:

$ git init

Stage a file (let Git know you will be committing this file at some point):

$ git add <filename>

Check the status of the current repo:

$ git status

Un-stage (revert a file):

$ git reset HEAD <filename>

Commit changes (with a message):

$ git commit -m "my commit message"

Add the entire directory to staging:

$ git add .

Display a log:

$ git log --pretty=format:"%h %ad | %s%d [%an]" --graph --date=short

 

I'm really liking Git already!

 

Posted in General, Git, Programming | Leave a comment

If you’re not using Git, you’re missing a trick

I fell in love with Subversion some years ago and now I use it daily. It's not perfect and I don't really use it to it's potential but it's pretty nifty for my requirements. Recently, the number of projects I've been managing has grown and with it the number of developers working on projects. The rate at which features are being added, bugs fixed, releases deployed has also increased tremendously and it isn't going to slow down any time soon. A side effect of all of this has been that I've started looking at the tools we use to develop, manage and deploy our code.

Subversion has worked well for us for a while but now, somehow, it seems clunky and slow. Maybe I'm not using it correctly but I've started looking at alternatives and well Git is the hot stuff strutting around town at the moment, so I've decide to give it a spin. Getting my head around how Git differs from traditional VCSes took a minute but while reading this post on branching and Git all the pieces fell into place.

The second place to go is to Git Immersion. The best way to learn is by doing and GI has that covered! After that, keep the SCM Book handy at all times. It will keep the hair on you head!

Hope these are helpful, I know it was to me.

Posted in General, Git, Programming | Leave a comment

Don’t do this – Mobile Usability

I received a text message today offering a 2 for 1 voucher from my local pub. I was quite impressed because the text message was very targeted and considering it is a pretty sunny day I thought it was very relevant. This was where my admiration ended. What follows is the steps I took to get the voucher. Ready?

I have a iPhone 3GS. My text message said to click on a link to get my voucher. I did so and was sent to my Safari app and the following screen was loaded:

Find a Proper Pub first screen

There was no mention of the offer on this page. I thought, maybe I need to go to the mobile site. So I clicked the "Or Continue To The Mobile Proper Pubs Website" at which point I was presented with this screen:

Mobile Proper Pub Website

Still no mention of the voucher. There was an advert for another thing I could win but not the reason I came to the site. So, being in the business of web applications, I think to myself, something must have gone wrong, let's try this again. I go to the text message and click the link again:

Proper Pub Mobile home screen from offer

Hmmm....still no mention of the offer. Being curious I decided to scroll down:

Advert revealed!

Aha! Here is the voucher advert. Now how to do I sign up? Erm, do I click the Terms & Conditions link? The advert itself isn't clickable, so what do I do now? At this point I had given up but decided to play around with the app. I put my post code in and clicked search:

Search results

I then clicked on the Butchers Hook because that is the pub closest to me and the one named in the original text message.

The Buthers Hook

Nice, my local pub. What else is there on this screen? After scrolling down:

The Voucher!

Wait, finally! The link to get the voucher! At this point I was no longer interested in this but was pleased to note that the voucher does actually exist somewhere in the app.

There are several issues with usability with this but the main problem is that the landing page for the link does not follow on from the original marketing message. Mobile developers need to realise that "above the fold" also applies to mobile screens, if I can't see something on my first screen, mobile devices usually don't give an clear indication that the screen is scrollable. Don't take anything for granted. Ever.

A redesigned version of this would include the following:

  1. Automatically redirect to the mobile site on detection of a mobile device
  2. Clear instructions for receiving the voucher on the very first screen shown to the user.
  3. Reduce the header, not really needed and just wasting precious space
  4. Move the Get Voucher link to higher up on the page, even before the details of the pub. I came for the voucher, not to find details of the pub!

 

I believe these simple changes would help to increase conversion rates and reduce customer friction by a significant percentage!

 

Posted in Conversion Rate Optimisation, E-commerce, Marketing, Mobile | Leave a comment

Managing CSS and JS

At iSUBSCRiBE (we sell magazine subscriptions) we developed a content management system that powers our primary website. When we originally designed the application framework the system would be stand alone. We didn't need additional websites. Inevitably business change required us to white label the site. Surprisingly the design lent itself to white labeling quite well. We were able to incorporate and manage the sites via the CMS quite easily. Management of assets on the other hand has proven to be more difficult.

Each white label requires a unique design and slightly different functionality, which we facilitate by keeping assets unique per site. This is a pretty logical way to handle these files, since the application itself has core files that are shared across sites with site specific design held locally. Consistency across core attributes however is a problem. For instance if jQuery is updated on the core system you want to keep this consistent across all the white labels, at present, this requires manual updating of each site. This can be annoying. A nifty little solution has been posted by Peter from GatherContent to help with these sort of issues. Check out the blog post http://blog.gathercontent.com/combine-and-compress-css-and-js-on-the-fly. Incorporating this into our build process will help with management of assets that need to be update to the latest version across every one of our sites without having to manually update each site individually.

Posted in ColdFusion, Javascript, Programming, Web 2.0 | Leave a comment