Git terminal prompt on a mac

Assuming you’re setting up on a shiny new mac, here is how you can add the git branch to the command prompt:

Grab these files and add them to the ~/ folder

Also then add a .bash_profile to that folder, easiest way is to open the terminal at that folder then use the touch command:

touch .bash_profile

Then add these lines to the file:

source ~/.git-completion.bash
source ~/
export PS1='[\W$(__git_ps1 ” (%s)”)]\$ ‘

Restart the terminal and you’re done!

Adding a self signed certificate to mac

Thanks to Rob Peck for these instructions on adding a self signed SSL certificate your key chain.

  1. In the address bar, click the little lock with the X. This will bring up a small information screen. Click the button that says “Certificate Information.”
  2. Click and drag the image to your desktop. It looks like a little certificate.
  3. Double-click it. This will bring up the Keychain Access utility. Enter your password to unlock it.
  4. Be sure you add the certificate to the System keychain, not the login keychain. Click “Always Trust,” even though this doesn’t seem to do anything.
  5. After it has been added, double-click it. You may have to authenticate again.
  6. Expand the “Trust” section.
  7. “When using this certificate,” set to “Always Trust”

Subdomain email with 123-reg

Paying for a subdomain can be avoided by using the advanced DNS option.

Obviously an A record is a simple enough thing to set up but mail has always been a sticking point for me, but no longer!

Assuming you have the hosting set up using a plesk or cpanel account, a lot of default DNS plumbing is done for you at that end, all you need to do is make sure the traffic is sent to the right place.

For example, lets say is registered at 123-reg and you’d like to use to run a site and email.

Set up the domain as usual in the with the host, so long as its set up for email (and it should be) all you have to do is set up an MX record with 123-reg such as:

sub     MX

It will be given a priority value by default. In a recent case, the DNS of the host showed a mail server on ‘’  pointing the MX record there didnt work but pointing it to ‘’ did!


Insert options smart buttons

I’m going through a list, checking duplicate values. When I need to insert a row, a button keeps popping up asking about formatting. Its dead annoying as it covers up the next values i need to check:

Screen Shot 2016-04-28 at 10.48.15

To turn it off, go to “Excel > Preferences > Edit” then untick the “Show insert options smart button”

Word language settings

There is nothing more annoying than having microsoft word tell you that the UK spelling of a word is wrong. The solution to this is so simple it makes me wish I’d found it years ago.

It’s even possible to change the language of the whole document or just a part of it. To change a part of the text, highlight that text and perform the following, to change the global language make sure nothing is selected.

Word 2011

    1. From the ‘tools’ menu, select ‘language’. The default is likely to be ‘English (US)’.
    2. Change the selection to the language of your choice.
    3. If you want ALL new documents to use that language, hit ‘Default’ then ‘Yes’ to confirm.

For window versions, i believe the language options are in the proofing ribbon, but look here for more info.

Off screen windows on a mac

Photoshop is a nightmare for this.

In the office, I connect my macbook pro to a cinema display but not at home. Switching between dual and single displays seems to cause some software – especially photoshop, filezilla and excel – to move their windows off screen. You can’t grab them to move them around so they are stuck out of reach.

There are some fixes for this.

Option + drag
If you can grab the edge of the application you can hit option and drag. This will resize both sides at once and might be enough to get things back into view.

Download Spectacle
Spectacle is a handy, open source app which lets you resize windows using keyboard shortcuts. I recommend running it in the status menu (this option can be set by pressing the ‘ > ‘ bottom right) at startup. If the keyboard shortcut doesn’t work then you can access the resize options from the spectacle icon in the status bar.

Spectacle is good – especially for a free app but if you want more, try SizeUp, its not free but it is cheap and adds things like padding to avoid shadow overlap.


If you are running low on storage space on an ipad or iphone and you have a huge amount of space being taken up by “other” files (shown in itunes summary) then this handy – and free – tool will clean it up

I had 1.9GB being taken up by ‘other’ files and had zero bytes of storage space, this software cleaned 1GB of logs and other crap.

Highly recommended.

Terminal – sublime text 3

Git is great but I favour the terminal rather than an app to manage repos which leaves me with the need to open terminals in the correct folder or spend valuable seconds on typing the path to the project.

I do have a way to open a new terminal from a folder but that means having to open finder, go to the project, right click and open the terminal. That can also be painful.

I work in sublime text all the time so wouldn’t it be handy to have a way to open terminals from there? Well, i just found a nice little package to do exactly that:

I had tried glue ( but thats not so good when running gulp and i’d like to use the up arrow to go back to previous commands. There’s nothing like running the actual terminal and now i have a way to quickly launch it. Just right click the folder your repo is in and ‘open terminal here…’