Let your Mac turn you into a ventriloquist

There are times that computers can be the most amazing devices; capable of automating mundane tasks, enabling communication with colleagues, friends and family or simply opening access to the great storehouse of knowledge represented by the interwebs.

It may take a second but shortly you will hear Alex’s voice emanating from your speakers. The ability to speak text directly from the command line is incredibly cool, but invaluable when you combine it with the ability to SSH into a machine.

SSH and Remote Access
SSH—which stands for Secure Shell—allows you to remotely access most Linux or Unix based machines, including Macs running OS X. First you need to make sure it’s enabled on the machine you want to remotely access. Go into System Preferences / Sharing and enable Remote Login. You will also want to make sure you have a named account on the remote machine.

You can connect to a remote machine by simply entering the following from a terminal prompt:

ssh <user>@<machine>

For me that’s:

ssh david@force

I won’t go into too much detail on how this works; that’s beyond the scope of this blog post. There is a lot of information on how you can get SSH working properly between two machines though. Google will help.

Once you’ve logged into the remote machine you can run command line applications. This is the method I use to access remote logs on my Macs and see if Time Machine has failed while I was away—which it invariably has.

If however you enter a "say" command while remotely accessing a machine Alex’s voice will emanate from the remote machine’s speakers, even if someone else is logged in and actively using the machine.