Tag Archives: macOS

How to install MySQL on Mac OS X El Capitan

MySQL 2015

There are several ways to install MySQL on your Mac, for example:

  • compile from source
  • use the Homebrew package manager (http://brew.sh)
  • use a nifty script courtesy of Mac Mini Vault (http://git.io/eUx7rg)
  • or use the dedicated MySQL installer package (recommended)

I recommend the dedicated installer because it’s the only package that will also add a convenient Preference Pane for starting and stopping the service.

In this article I’ll focus on the latter, and I’ll also talk you through how to add MySQL to the PATH variable and how to secure MySQL to keep the evildoers away from your server.

These instructions will work on Yosemite and El Capitan (I’ve tested it on both systems – in fact that’s part of why I’m writing this, so that I can remember for next time).

 

Screen Shot 2015-11-02 at 10.40.12

Continue reading How to install MySQL on Mac OS X El Capitan

How to enable automatic user logins on Mac OS X Yosemite

Screen Shot 2014-08-23 at 17.49.01By default Yosemite doesn’t like users to auto-login when the system starts. Instead you have to select a user, type in the password, and then the system starts to boot. Not necessarily what we want.

To disable this feature you usually head over to

  • System Preferences
  • Users and Groups
  • Login Options

and pick your default user from that handy drop down menu. Notice however that this is greyed out on Yosemite:

Screen Shot 2014-08-23 at 17.47.59

So what gives?

Turns out that this option is not available if you’ve agreed to encrypt your disk via FileVault. And it makes sense too: otherwise your hard disk data could be accessed upon boot without a password, rendering this feature useless.

Hence, to bring back automatic logins, turn off FileVault under

  • System Preferences
  • Security and Privacy
  • FileVault

Screen Shot 2014-08-23 at 17.56.24

According to this system, I can do that in about 32 days…

Notice that if you use your iCloud password as the login password, auto-logins are also disabled. In which case, change your login password to a “separate password”, switch off FileVault and voila – auto logins are back at your disposal.

Screen Shot 2014-08-23 at 18.02.06

  • http://forums.macrumors.com/showthread.php?t=1757742

How to update Microsoft Office for Mac 2011 – despite Microsoft Database Daemon and SyncServicesAgent errors

Every time I try to update Microsoft Office 2011 on my Mac I get this ridiculous window popping up. No matter how hard you try, those two services – Microsoft Database Daemon and SyncServicesAgent – keep relaunching themselves, forever preventing you to apply the update.

Clearly Microsoft (or Apple) don’t want us to update Office for Mac:

Screen Shot 2014-07-31 at 14.49.45Usually I give up and live without such updates. I only use M$ Office once in a blue moon and really don’t care. Today I got curious and researched this phenomenon – and thought I’d tell you about it.

Several suggestions are available to combat this superb example of a terrible user experience:

  • rename those processes
  • log out, then log back in with the shift key held down
  • go offline just before this message comes up
  • kill the processes with the Activity Monitor Utility

None of those suggestions worked for me, and besides: what a hack any of these solutions are to apply a simple security patch.

What did work was a very clever suggestion by someone named vrleboss: Use a while loop on the command line and continually kill those processes until you’re done.

Here’s how to do it: Open the Terminal utility on your Mac and paste the following code:

You can do this without quitting anything else, even while the pesky “close applications” window is displayed. Make sure the whole command is on the same line. The is a BASH loop that will find both processes and kill them as soon as they start up again. Don’t worry about the continuous text output in the window.

Back in the Microsoft Updater window, hit “Close Applications and Install”. Now it works!

Once the update is applied, head back to the Terminal window and press CTRL+C – this will stop the killing loop. Close Terminal and Office for Mac is finally updated.

Then repeat this process next week, when another 140MB of updates will have to be applied.

Watch the Screencast

  • https://discussions.apple.com/thread/3928408?start=30&tstart=0

Update May 2015

Looks like Microsoft have finally found a way to make updates happen without the necessity for such backdoor hackery. Since version 14.5.0 I was able to update both my systems without the above code.

I thought I’d take a screencast on this happy occasion (because I still can’t believe it myself):

Catch this episode on my WP Guru Podcast:

How to populate an NSTableView in Code

In this screencast I’ll show you how to power an NSTableView using code. I’m referencing this article for code snippets and details: http://pinkstone.co.uk/how-to-populate-an-nstableview-in-code/

I’ve also made a “no-code” version on how to populate an NSTableView using an Array Controler and Cocoa Bindings here: http://pinkstone.co.uk/how-to-bind-an-nsarraycontroller-to-an-nstableview/

Enjoy!

How to bind an Array Controller to a Table View with Cocoa Bindings

In this screencast I will show you how to bind a Table View to an Array Controller in Cocoa, using Xcode 5.1 and OS X Mavericks. We’re using Core Data to save our entries and – check it out – we’re not writing a single line of code!

Cocoa Bindings is one of the most exciting features in OS X development for me, and I hope that one day it’ll find its way into iOS too.

The project is also available on GitHub: https://github.com/versluis/Bindings-Demo

I’ve written more about how to do this here: http://pinkstone.co.uk/binding-an-nstableview-to-core-data-without-code/

How to use Branches in Xcode

In this video I will show you how to use the Git Branch feature in Xcode 5.1.

Branches are helpful if you’re developing your app. You can isolate a “working” version, create a new branch and fiddle with new features that may destabilise your project. You can then commit your changes – working or not – to a separate branch, and when all is stable again you can merge them back into the master project.

I use this feature for plugin and theme development, in fact for any “group of files” that will change over time. If you’re not using Xcode, take a look at the GitHub Apps which are available for Mac and Windows. They make version control a breeze on your local system, integrate flawlessly with GitHub.com as well as SSH remotes on your own server.

  • https://windows.github.com
  • https://mac.github.com

How to use Git Tags in Xcode

In this video I will show you how to make use of Tags in Git. This is not supported in Xcode or GitHub for Mac at the time of this recording (April 2014). I will also show you how to utilise the Tag/Release feature on GitHub.com.

Tags are a useful feature if you want to mark versions of your software before you add new features. With Tags you can always go back to the code of a release.

We’re using Xcode 5.1 and the Terminal utility for this.

I use tags and branches for plugin and theme development too, in fact for any “group of files” that will change over time. If you’re not using Xcode, take a look at the GitHub Apps which are available for Mac and Windows. They make version control a breeze on your local system, integrate flawlessly with GitHub.com as well as SSH remotes on your own server.

  • https://windows.github.com
  • https://mac.github.com

How to remove data from your iCloud Storage

Apple_Podcast_logoTrouble backing up your device to iCloud? Is your storage constantly at the limit and you don’t know what to do about it?

Fret not! In this video I will show you some option you have to deal with that dreaded message “Not enough iCloud Storage”.

Essentially there are four things you can do to prevent this problem:

  • buy more iCloud Storage
  • backup less data (for example, don’t backup pictures)
  • remove older iCloud backups (think of devices you no longer own)
  • use less iCloud Document Storage (remove data from iMovie Theater, Shared Photostreams)

I will demonstrate all these options on my iPod Touch and show you how it works.

Enjoy!

 

Getting Started with ZEND Server 6 on Mac OS X

ZEND_logo

I’ve just installed ZEND Server 6.3 on my MacBook running Mavericks 10.9.1. Needless to say I’m sill a little shaken up from the huge amount of brain pain this adventure has caused.

Because once downloaded and installed on your system, you may ask yourself a vital question: Now What?

Let’s find out. This article is Work in Progress – bear with me while I flesh it out.

The Basics

ZEND Server on Mac is located here:

  • /usr/local/zend/

Your web files live here:

  • /usr/local/zend/apache2/htdocs

To open this directory in Finder you can navigate there with a Terminal session and open it, like so:

Now you can create a shortcut on your sidebar for easy access.

To access the ZEND Server Admin interface, navigate to the following URL in your browser:

  • http://localhost:10081/ZendServer

If you’re done with it, you can uninstall ZEND Server with the following command:

Continue reading Getting Started with ZEND Server 6 on Mac OS X

How to install ZEND Framework for use with MAMP

ZEND_logoIf you have MAMP installed and working on your Mac, it’s easy to get started with ZEND Framework development. I’ll show you how in this article.

Download the framework from here:

  • http://framework.zend.com/downloads/latest

Choose the full version without ZEND Server (not necessary as we’re using MAMP). Unpack the download and put it somewhere safe. I’m adding mine to my Documents directory. I’ll also rename my folder to something like “ZendFramework” without the version number.

To access it from anywhere on our machine we’ll create an alias named “zf”. zf is a shell script provided by the framework that we’ll need throughout our development journey with ZEND. Let’s to this in a Terminal session:

Replace the path with your own. Notice the call to /bin/zf.sh which is the “real” shell script. Our alias has just made this universal and accessible without having to mess with our shell path.

Verify that it’s working with this:

Read the full article