This weekend I’ll be giving Monodraw a test drive. It’s an ASCII-art drawing program for Mac OS X. If it’s as good as advertised I may use it to draw images for my new book.
If you ever need to copy text (or a text file) from the MacOS Terminal to the Mac clipboard, I can confirm that the macOS
pbcopy command works. It reads from STDIN and copies the text to the clipboard, so commands like these work:
$ echo "foo bar baz" | pbcopy $ cat /etc/passwd | pbcopy
As a quick note, this is a list of the IntelliJ IDEA keystrokes I use on my MacOS systems:
I don’t have much time to explain this today, but ... if you want to see how to use the
sed command on a Mac OS X (macOS) system to search for newline characters in the input pattern and replace them with something else in the replacement pattern, this example might point you in the right direction.
According to Forbes and other sources, Apple now has its own version of a “Stagefright” security flaw, and it affects all but the most recent versions of iOS and Mac OS X. Theoretically all it requires is that a hacker sends your phone one text.
I haven’t solved my overall problem yet — which is how to fit 64 GB of music onto a tablet with 24GB free space — but I did solve another problem today: How to show the largest files under a directory on Mac OS X (and Unix systems). In this short tutorial I’ll demonstrate what I learned.
A command to show the largest files under a directory on Mac OS X
The Unix command that worked for me on my Mac OS X system is this:
As a quick note today, I have been converting parts of the Scala Cookbook from a plain text format to a Markdown format, and as part of that I needed to add some newline characters to add spacing to the document. This wouldn’t be bad if it was a few pages, but it’s hundreds of pages, so I decided to use the Unix
sed command to do the work.
Mac OS X 10.9 has been sucking the life out of my old Mac, a 2008 iMac, so I decided to look into ways of bringing life back to my Mac. One way I just wrote about is how to disable the OSX Dashboard. Another way I’m experimenting with is the Mac OS X =purge= command.
OS X 10.9 is sucking the life out of my old Mac, a 2008 iMac. Like turning off everything on Star Trek’s Enterprise so you can give power to something else (like the engines or shields), I keep looking for ways to bring a little life back to it. One way I’ve read about is to kill the Dashboard on 10.9.
You can kill the Dashboard with this Mac OSX
defaults command, issued in a Mac Terminal window:
Since upgrading to Mac OS X 10.9 I’ve experienced the problem other people have reported, where their Mac won’t shutdown, or shuts down very slowly. We had a huge lightning storm roll in a few days ago, and when my 2008 iMac didn’t shut down after three minutes of waiting, I finally had to press and hold the button on the back to force it to shut down.
Since then I’m glad to say that the following series of
defaults write commands has helped my iMac to shut down much more quickly: