Engadget RSS Feedhttps://www.engadget.com/tag/terminal/rss.xml
https://www.blogsmithmedia.com/www.engadget.com/media/feedlogo.gif?cachebust=trueEngadget RSS Feedhttps://www.engadget.com/tag/terminal/rss.xml
en-usEngadget is a web magazine with obsessive daily coverage of everything new in gadgets and consumer electronicsCopyright 2018 AOL Inc. The contents of this feed are available for non-commercial use only.https://www.tuaw.com/2014/05/05/how-to-copy-text-when-previewing-a-document-using-quick-look-in/https://www.tuaw.com/2014/05/05/how-to-copy-text-when-previewing-a-document-using-quick-look-in/https://www.tuaw.com/2014/05/05/how-to-copy-text-when-previewing-a-document-using-quick-look-in/#comments

Quick Look is a fantastic feature that makes it easy for you to preview documents in the finder window with just a simple tap of the space bar. You can make the feature even more powerful with this terminal command that adds a copy function to any text you are viewing in the Quick Look window.

As reported by LifeHacker, you can use the following terminal command in the OS X terminal app to enable text selection in Quick Look:

defaults write com.apple.finder QLEnableTextSelection -bool true

killall Finder

Once the text function is enabled, you can select text as shown above in blue and then use command-C to copy it to the clipboard. If you want to turn off the text selection and copy option, just change the value of "true" to "false" in the terminal command as shown below:

defaults write com.apple.finder QLEnableTextSelection -bool false

killall Finder

Once this feature if turned off, Quick Look will return to its original state, allowing you to read a document and not select any text.

I love OS customization. Don't you? Ever since OS X Mavericks debuted, I've been complaining about the nearly solid dock. Finally, I stumbled across a system setting that enabled me to restore my dock to its pre-Mavericks more-translucent look.

As with many tweaks, the solution depended on a Unix command-line directive to the defaults (that's Mac for "settings") system. You enter this at the Terminal (/Applications/Utilities/Terminal), specifically:

defaults write com.apple.dock hide-mirror -bool true

After updating the defaults database, you need to restart the Dock:

killall Dock

The screenshots on the right of this post show the results. Using the normal settings, you can barely see through the dock at all. Once you apply the mirror hiding override, the dock becomes far more translucent, enabling you to see more of the desktop below it.

I own Microsoft Office 2011 and wanted to make the process of installing it easier, since I own several Macs and have this habit of reinstalling OS X frequently. So I wrote a shell script because that's what I do to solve these sorts of problems. The best part of the script is that it does not require you to have any of the necessary parts. You do not need your installation DVDs or to have downloaded the latest updates.

Once you start the script, it will download everything that you need directly from Microsoft's servers and install all of them for you. The entire process can be left completely unattended after it is started. The length of time for the install process depends on your network speed. The total download size is 1.16 GB (aka 1.08 GiB or 1,157,294,708 bytes) as of today.

Once the script is finished, the necessary files will be available in ~/Downloads/Office2011/ which you can then copy to any of your other Macs. The script will look for files in ~/Downloads/Office2011/ and if they already exist, it will not download them again.

Once the script finishes, it will run "Microsoft AutoUpdate.app" to make sure that there are not additional updates necessary.

How to use this script (The Easy Way)

There is an installer available. This is an Automator app which will simply download and run the office2011.sh for you.

Please note that because of Gatekeeper settings in OS X, you may have to right click the installer app and choose open in order to get it to launch.

Once you confirm that you want to download and install Office, the rest will take place behind the scenes. You will be prompted to enter your administrator password because the installation cannot continue without it.

Update 2013-12-29: I have updated the information at GitHub to include a walk-through of using the GUI Installer application. If you tried it before and it did not work, please try again.

How to use this script (The Nerdy Way)

A better way to use this script requires the Terminal.app which is found in /Applications/Utilities/. Using Terminal is like getting under the hood of your car: it shouldn't scare you, but you shouldn't just go randomly poking around either.

Note that you will have to enter your administrator password to use sudo.

After Installation

Once the installation finishes, Microsoft's Auto Update app will be launched. This will make sure that there are no additional updates needed which have been released since this script was written. It is also a good time to set the auto-updater to run as often as you'd like it to run automatically. I recommend once a week.

Disclaimer and Final Notes

As far as I know, installing Office 2011 this way gives you the same result as if you had installed using OS X's Installer.app on the various pkg files directly. However, there's a chance that I could be wrong. Use at your own risk, etc.

The only difference that I am aware of is that installing Microsoft Office using these scripts does not automatically add the apps to your OS X Dock. This is considered a feature, not a bug.

Using this installer will not give you free access to Microsoft Office 2011. The first time you run it, you will be asked for your license code or Office 365 subscription information. If you do not have either of those you can use a trial version of Office, but I do not know what kinds of limitations it places on you. Discovering those is left as an exercise to the reader.

I have known about OS X's "Single Application Mode" for a long time, but a new feature in Mavericks has me testing it out again. According to an article on TidBITS, Single-Application Mode was introduced in 1999 with the (then) new Finder in Mac OS X. "Single-Application Mode" meant that when you switched from one app to another using the Dock then the new application that you had selected would come to the front, and the other applications would automatically hide. According to the TidBITS article, this was initially intended as the default behavior for the Finder, but public reception was so bad that so Apple dropped it as the default. However, the feature has continued to exist ever since.

Now, 14 years later, Single-Application Mode brings a new benefit for people using Mavericks thanks to the new "App Nap" feature which will reduce the CPU/energy/battery usage of applications. The easiest way to take advantage of the App Nap feature is to have all of the windows of a background application completely hidden. (For a fuller description of the App Nap feature, see Siracusa 9:13 and 9:14 over on ArsTechnica.) These two features seem like a match made in Timer Coalescing heaven.

To enable this feature, you have two options: The easy way is to download and install the Secrets preference pane and search for 'single' in the Finder preferences. Check the box, and then restart the Dock. The nerdier option is to go into Terminal.app and enter these commands:

defaults write com.apple.dock single-app -bool true ; killall Dock

which will enable the feature and restart the Dock (which is necessary for the new setting to be registered. If you later decide that you do not want to use this feature, use

defaults write com.apple.dock single-app -bool false ; killall Dock

or

defaults delete com.apple.dock single-app ; killall Dock

to disable it.

If you enable this and need to see two different apps at the same time, use ⌘ + Tab to switch between the apps instead of clicking on the dock icons.

Keyboard Maestro offers the same idea for those who prefer to switch apps using the keyboard instead of the dock.

There is another way to do this without using the Dock method if you use Keyboard Maestro. One of the default macros that comes with Keyboard Maestro is a ⌘ + Tab replacement. It has several enhancement options as shown here.

"Hide other applications when switching" is the feature that relates to our main topic here. With that enabled, any time you switch between apps using ⌘ + Tab, Keyboard Maestro will hide other apps. That gives you effectively the same functionality as Single-Application Mode without changing your dock settings. If you use this feature, you can see multiple app windows by switching between apps by clicking on the dock icons instead of using ⌘ + Tab.

Just be careful that you don't enable both of these options at the same time unless you always want to use Single-Application mode!

Keyboard Maestro gives you some other useful features such as: "Place switcher under mouse" means that the icons will appear wherever the mouse is, so you can easily choose one of the apps with your mouse if you prefer. You can also choose some applications which will always appear in the ⌘ + Tab list, even if they are not running. For example, I have added BusyCal, BBEdit, Messages, and MailMate, which means that I can switch to those apps, and if they are not already running, Keyboard Maestro will launch them. So now I no longer have to keep apps running just because I might want to use them again later.

In fact, after trying both methods, I decided that I preferred to use Single-Application Mode via Keyboard Maestro instead of the dock, because I switch between apps using ⌘ + Tab much more often than by clicking on the dock icons. On those occasions when I do need to see more than one app at a time, I find it easier to just click the necessary dock icon.

How much battery life does this save?

The answer is that I really don't know. Trying to do comparisons of real life battery usage would be nearly impossible, and probably a waste of time. So far, I find that I prefer this "Single-Application Mode" most of the time, and so the energy benefits are just a nice fringe benefit. Then again, I spend most of my time using a 13" MacBook Air. If you use a 27" Cinema Display or multiple monitors, it might not be as useful for you, but as Apple's emphasis on energy usage shows, they are seeing a lot of growth in the number of MacBook users. If you're one of them, especially if you are trying to squeeze as much battery life as possible out of your MacBook, maybe it's time to give Single-Application mode another look.

After a minor curfew scuffle, it looks like Google might soon take its airplanes from their current nest at Mountain View's Moffett field and park them up the road at Mineta San Jose International Airport. Signature Flight Support has been approved by the city's council to build an $82 million facility on the west side of that field, where its biggest client would be Google's flight operator, Blue City Holdings. Councilmen approved the facility by a 10-1 vote after Signature accepted a deal for immunity from some of the stricter measures of a night flying curfew, like eviction. Google's offer to do a $45 million renovation of Hanger One at its current Moffett Field home in Mountain View was rejected by the feds, meaning the search giant's likely to take its ball, bat and fleet of jets to San Jose sometime in 2015.

Now that the SEC has given companies its blessing to share business data over social media, Bloomberg has begun to pull live Twitter feeds into its market terminals, known as the Bloomberg Professional service. According to the firm, that makes it the first financial information platform to integrate real-time tweets into investment workflows. Within the service, tweets are classified by company, asset class, people and topics, and stock buffs can even search messages, create filters and set alerts to notify them when a certain subject gets a flurry of mentions. The outfit hopes the inclusion of 140-character missives will let financial-minded folks keep their fingers on the market's pulse without switching to another system (read: being distracted by Tweetdeck) to get the big picture. Hit the jump for the full skinny in the press release.

If you use your Mac for any period of time, you will find the need to open a document with a different program other than the one set as default. The "Open With" menu appears in the Finder whenever you right-click or control-click on the icon of a document. The "Open With" command is designed to give you a list of alternative choices to handle the file that you've selected, but after long-term use you will find this list can get a little bit messy.

Duplicate entries in your "Open With" menu can be easily cleaned via a simple terminal command. We initially covered this command in a 2009 post about rebuilding your launch services, but this post is updated with video and a few new methods that'll work in OS X Mountain Lion. In the video below, I will demonstrate the basic terminal command. I will also show you how to create a bash script to make it easier to repeat this cleaning whenever needed, as well as create an Alfred workflow to do the same (requires the Alfred powerpack.)

Below you'll find the commands used in the video. If you are creating the .bash_profile alias method, remember you will have to quit and relaunch terminal for this to work.

Fix Duplicate "Open With" Terminal:

Fix Duplicate "Open With" via Bash alias:

If you are a little shy of monkeying around in terminal and bash, you can use utilities such as Onyx or Cocktail to get the job done.

When writing shell scripts, I often send interactive output to the user via echo to give feedback or information. But if the shell script is called on a schedule via OS X's behind-the-scenes process launcher launchd, rather than from a Terminal session, chances are that I won't ever see that message.

Fortunately, it's relatively easy to figure out if a shell script has been called from launchd or not, simply by checking the $PPID variable. (Note: this works in zsh and may work in bash as well. If it doesn't work in your shell, this is a good time to upgrade to zsh.)

But how can I make sure my messages are seen if a shell script has been called via launchd? For that I use the Swiss Army Knife of notification tools, Growl. Specifically, I use the growlnotify optional package, which allows me to send Growl notifications from shell scripts.

For example, imagine that I wrote a script where I wanted to tell the user that a certain process had succeeded or failed. Normally I might just use

echo 'SUCCESS!'

or

echo 'FAILED!'

But now, instead of 'echo' I use a function called msg (short for 'message'). If the script was called from launchd then msg will use growlnotify, but if the script was called from the command line, it will just use echo. Here's how that works:

This method is not foolproof. For example, if you call a shell script from launchd and that shell script calls another shell script, it might not realize that it was originally executed from launchd. In practice, I have not run into that problem, but it did seem worth mentioning.

AT&T's video archives are rich seams of juicy historical tidbits, and today's offering is a fine example. It's sharing footage of the Bell Blit, a graphic interface that Bell Labs developed after being inspired by the Xerox Alto. Originally named the Jerq, it was created by Rob Pike and Bart Locanthi to have the same usability as the Alto, but with "the processing power of a 1981 computer." Watch, as the narrator marvels at being able to use multiple windows at once, playing Asteroids while his debugging software runs in the background on that futuristic green-and-black display. The next time we get annoyed that Crysis isn't running as fast as you'd like it to, just remember how bad the geeks of yesteryear had it.

In the spirit of Tim Cook's maniacal excitement about upcoming Apple products, I bring to you the shell script you can run repeatedly from the command line to check the App Store to see if Mountain Lion is ready for purchase.

This is what I used last year to check for Lion; it worked. This year, I update the search string to "Mountain Lion" instead.

As presented, it employs a 10-minute time-out, so you can run a repeat command with it.

Call of Duty Elite members on Xbox 360 will get a new content drop in Modern Warfare 3 on Tuesday, July 17: three new multiplayer maps and a Spec Ops mission.

The multiplayer maps include a graveyard of derelict ocean liners called Decommission, an oil rig built for sniping called Offshore, and the remake of Modern Warfare 2's Terminal map, available to Elite members on Tuesday and free for the rest of Modern Warfare 3's Xbox 360 players the following day. In the Spec Ops mission, Vertigo, players must take down enemy troops and helicopters while perched atop the Oasis hotel.

On Thursday, July 19, Call of Duty Elite subscribers on PS3 get to tussle with three new Face-Off maps and a Spec Ops mission, content released on Xbox 360 back in June. Multiplayer maps include a tornado-rocked town called Vortex, a dilapidated middle-eastern highway in U-Turn, an urban NYC-based map called Intersection, and the Spec Ops mission, Arctic Recon, which tasks players with assaulting a Russian warship.%Gallery-160351%
]]>
arctic-reconcall of dutycall of duty: modern warfare 2call of duty: modern warfare 3call-of-duty-elitecall-of-duty-modern-warfare-3decommissionintersectionmicrosoftmiddle eastmodern-warfare-3offshorepcplaystationps3sci/techspec-opsspecial forcesterminalu turnu-turnvertigovortexxboxFri, 13 Jul 2012 13:50:00 -040011|20277703https://www.joystiq.com/2012/07/05/modern-warfare-3-hits-terminal-condition-july-17-for-free/https://www.joystiq.com/2012/07/05/modern-warfare-3-hits-terminal-condition-july-17-for-free/https://www.joystiq.com/2012/07/05/modern-warfare-3-hits-terminal-condition-july-17-for-free/#comments

The popular Modern Warfare 2 airport map, Terminal, will come to Modern Warfare 3 on Xbox 360 on July 17 for Elite members and July 18 for non-Elites, but free for everyone, regardless of digitized classist regulations.

Terminal, the popular airport map from Modern Warfare 2, is heading to Modern Warfare 3, Infinity Ward's Mark Rubin has revealed via a series of tweets. Better still, Rubin says Terminal will be free for everyone, existing outside of the Elite subscription model.

Rubin says Terminal is in Microsoft certification now and the release date and official confirmation may not go public until Thursday or Friday. The map isn't confirmed to hit Xbox 360 first, but that is still an option. It may even drop as a title update, rather than a separate batch of DLC. MP1st has compiled a few of Rubin's tweets in one place, but he's still at it on his own feed.
]]>
call-of-duty-modern-warfare-3dlcmapmicrosoftmodern-warfare-2modern-warfare-3pcplaystationps3terminaltitle-updatexboxTue, 03 Jul 2012 23:00:00 -040011|20271344https://www.engadget.com/2012/05/17/rogers-and-cibc-make-blackberry-mobile-payments-deal/https://www.engadget.com/2012/05/17/rogers-and-cibc-make-blackberry-mobile-payments-deal/https://www.engadget.com/2012/05/17/rogers-and-cibc-make-blackberry-mobile-payments-deal/#comments

Canadians sometimes can't catch a break: while NFC payments have been relatively common for Americans, Europeans and certainly the Japanese, Canucks have had to largely make do paying with ye olde credit carde. Rogers and national bank CIBC want to put an end to these antediluvian ways: starting later this year, CIBC card holders will just need to swipe an NFC-equipped BlackBerry like the Bold 9900 (Bold 9930 for CDMA-loving Americans) at a matching terminal to pay at a given store. The only special requirement is a secure SIM card that gives customers the freedom to change phones, even if it does create problems switching banks or carriers down the line. We're just hoping that Android and other platforms get the same treatment and let more of our Canadian friends pay for poutine that much faster.

VeriFone has decided that calling out claimed security holes and focusing on enterprise-level payment options aren't enough to take on Square. Sail goes more directly for Square's jugular, using its own plug-in dongle to handle major credit card payments in your local coffee shop or a mid-sized outlet. The VeriFone party trick comes through having multiple payment options, where shopkeeps can either choose to pay a flat 2.7 percent cut of every sale, or shell out a $10 monthly fee to lower the transactional take to 1.95 percent. Programming interfaces will let you hook in deals from social networks, too. And as you might expect, the company is still keen to tie Sail to its traditional payment systems, opening the door to NFC readers as well as other payment hardware that isn't quite as mobile. Stores with iPhones will be the only ones using the free Sail mobile apps and readers at first, but Android- and iPad-toting entrepreneurs will have their alternative to Square or PayPal Here as soon as the end of May.

There's quite a few tricks here, including the ability to have to multiple iCal windows open at the same time. You also can expand the week view to glimpse up to 28 days at once, which is a little too much. But like ZDNet says, being able to see two weeks at a time in week view is pretty handy.

To switch the views, select the desired time from the "top sekret" menu and toggle between week and another calendar option. The new mode is enabled once you return to the week view.

The excellent ReadNow application, which allows you to easily read articles from your Instapaper and Read It Later articles on your Mac, has been pulled from the Mac App Store "...because of an infringement letter." Developer Michael Schneider added "[i]n my current situation I'm not allowed to provide any further information."

The good news is that if you have already purchased the app, you can still download it from the "Purchases" tab in the App Store.app even though the iTunes page for ReadNow now leads to the message, "Your request could not be completed."

However, as I waited for the Mac App Store to load on my iMac this morning, I found myself wondering "What would I do if I couldn't re-download it from the Mac App Store?"

Fortunately I have the app on my MacBook Air, so I could go to /Applications/ReadNow.app and then select File » Compress "Read Now" (or control+click the app and choose "Compress" from the menu).

Terminal option

If you wanted to make a copy of ReadNow (or any app) on the command line, I believe that your best option is using ditto like this:

sudo ditto -v --keepParent -kc ReadNow.app ReadNow.zip

(I don't claim to be a ditto expert, but I can tell you that worked for me. The -k option tells ditto to make zip archives. The --rsrc --extattr and --qtn options are all the default, so they don't need to be explicitly specified.)

I then copied the 'ReadNow.zip' file to my Dropbox so I would have it, just in case Apple removes the option to download it.

This should work for all Mac App Store apps (Xcode and "Install Lion" excepted), but may not work for other apps which use an installer and may install other files besides the ones in /Applications/.

Show me all of my Mac App Store apps

Speaking of the command line, if you want to see a list of all the Mac App Store apps that you have installed on your computer, you can run this command in Terminal.app:

Note: this won't show you Xcode, because Xcode is an unusual case. It is an installer which installs Xcode and then the installer is removed.

An ounce of prevention

There has been no indication that Apple will remove ReadNow from your list of Purchased apps, I just wanted to have a backup 'just in case.' Hopefully the "infringement letter" issue will be settled soon and it will be available again. However, if the iOS App Store is any indication, eventually jettisoned apps will become unavailable for re-download. Also, the upcoming sandboxing requirements may lead to some existing applications being removed.

As always, it's good to have your own backups rather than relying on being able to re-download anything from "the cloud." I wrote a small shell script which will look in /Applications/ for any applications which have the Mac App Store receipt, and create a .zip file for each of them. (While I have tested it myself and it works for me, YMMV, use only at your own risk, etc.)

To use it, download the script to your Desktop (or wherever) and then run:

chmod 755 ~/Desktop/backupmas.sh

And then run it via

~/Desktop/backupmas.sh

(Obviously if you saved it somewhere else, use that path instead of ~/Desktop/.)

It may ask for your administrator password. If so, that's the one you use to log in to your computer, not your Mac App Store password.

There's an easy way in OS X 10.7 Lion to convert video or audio from one format to another, using a fixed suite of conversion settings. One approach uses Automator and can be launched from the Finder. The other uses the Terminal application and the afconvert (for audio) or avconvert (for video) command-line utilities. Behind the scenes, though, Automator is simply serving as a convenient front-end for the CLI tools. (You can also use the free Hoot app from the Mac App Store to do the same audio conversions.)

The Automator method is the easiest to start with. Simply select the video or audio file you want to convert in the Finder. Under the Finder menu, choose the Services submenu, then "Encode Selected Video Files" or "Encode Selected Audio Files." You can also get to the Services submenu via the Finder's contextual menus; right-click the target file (or control-click, or on a trackpad, two-finger click) and the Services choices will be at the bottom of the pop-up menu.

Finder menu / Services submenu

Contextual pop-up menu

Either approach will launch a dialog box where you can select your media conversion settings and the target file's destination. You can process one file at a time or, if you select multiple files, they'll be tackled in a batch conversion. The settings are slightly different for audio and video files, as appropriate to their media types -- you can experiment with the different settings to find the format that works for you.

Video encoding settings

Audio encoding settings

For those of you more comfortable with the command line, you can use afconvert to encode an audio file from one format to another or avconvert to do the same with video. Type "afconvert -h" in Terminal to get a list of all the options you can use in the audio conversion.

The avconvert tool is new in OS X Lion. Besides transcoding, it also lets you extract the audio or video track from a clip, change frame rates, add closed captioning and more.

Here on the Daily Mac App we love apps that do one thing really well. Today's app is no exception.

Go2Shell is a tiny little 0.3MB app available for free from the Mac App Store that has the potential to speed up your work-flow if it involves Terminal. Go2Shell simply launches a Terminal session with the current folder you're navigating in Finder, or the folder that Go2Shell is located in, open for work. It even supports iTerm, iTerm 2 and xterm if you're not a fan of Apple's own-brand Terminal.

It's so simple, it's almost beautiful and if you happen to have to modify files in Terminal, or any other similar task, Go2Shell could be just ticket to save you time. The best way to use Go2Shell is to drag it onto your Finder toolbar and from there launch it whenever you're in the desired directory.

If you need something a little more advanced you should check out one of our previous Daily Mac Apps, DTerm, which gives you hotkey access, and a floating entry form into the Terminal session.

Go2Shell is a great free download from the Mac App Store that does one thing and one thing well. So if you're a Terminal guru (even the app's preferences are accessed through the command line) then give Go2Shell a whirl. You might like it.

The Terminal is a Mac power-user's best friend. When you need to get something specific done, access the underlying system, modify files or change some settings, command line is often the best and only way to get it done. Instead of having to go to it, DTerm brings the command line to you.

Working in the command line normally means stepping out of your current workflow and stepping into Terminal. Although it can affect anything on the system, and helps you get the job done, it's a very separate process. DTerm, which we covered back in 2008, makes Terminal access context-sensitive.

From anywhere in any program you can invoke DTerm using a user-configurable global hotkey, from there you can run commands on the files you're currently working with. No need to manually go through and navigate to the correct file directory, DTerm takes your command line session right there, already set to your current working directory. You can even insert the currently selected documents directly into the command line making it quick and easy.

You can run your commands as you normally would, right from the floating DTerm window and even copy them straight out of the prompt. Once you're done you can just hit escape, use the hotkey combo again or simply ignore DTerm and it'll automatically fade out.

DTerm brings the command line to you, integrating it more effectively and quickly into your work flow. It's a free download from the Mac App Store and is compatible with Lion. If you ever find yourself in Terminal as part of your workflow, give DTerm a whirl and see whether it speeds up your command line sessions.

Lion. We love the OS. We hate a few tiny details. Here are five extremely handy Lion tweaks that can improve your day-to-day use. Enable each by typing the supplied commands into Terminal.

1. Turn off those #*%(ing zooming windows Launch Safari or TextEdit and then hit Command-N a few times. Do you see how the new windows fly or "zoom" into place? You can disable that with this elegant tweak from TUAW reader Ryan Hauk. First, open Terminal and type the following:

Finally, quit and restart whatever app you're looking to de-zoomify. You do not have to set the defaults more than once, but the apps won't pick up the new setting until their next launch.

2. Enable key autorepeat. You won't be able to use those cool iOS-inspired, press-hold-and-select-an-accented-character feature, but you'll get back thissssssssssssssssss. Courtesy of belchak.com.

defaults write -g ApplePressAndHoldEnabled -bool false

Interestingly, you can set this preference on a per-application basis. So you can enable key-repeat for, say, TextEdit but not for Safari by using e.g. com.apple.TextEdit instead of the global domain.

3. Make your ~/Library folder visible. This removes its hidden flag, so you don't have to keep using the option-key from the Finder's Go menu.

chflags nohidden ~/Library/

4. Disable spelling correction. When you want to be able to refer to "nethack" or "Megs" without it being autocorrected to "netback" and "Mess," you can turn this off from the command line -- or, if you prefer, get somewhat more granular control in the Text section of the Language & Text system preference pane (uncheck 'Correct spelling automatically').

5. Mandate scrollbars. Let scrollbars become a permanent part of your windowing experience.

defaults write -g AppleShowScrollBars -string Always

And 6. Add back the Finder's size information. (Via TUAW reader 1TallTXn) Open a Finder Window and use Command-/. Presto

And 7. Disable mail animations. Chris Pirillo sent me link to his how-to write-up, which uses this command (discovered by "Adrian") to simplify visuals when replying in Mail.

defaults write com.apple.Mail DisableReplyAnimations -bool YES

Have you found more good prefs? Let us know in the comments! Some good places to check are the Preferences folders (global and local), the HIToolbox, and Core Services.

Update: A reader pinged me to ask if I had come across any prefs that I didn't include because I wasn't sure what they did. Yes. Yes, I did. Here are a few for you to mull on: AppleUseCoreUI, AppleMagnifiedMode, AppleMenuSwipeDrivesMenuBar, and AppleUseSharedMenuBar. There are lots more like these in HIToolbox.

Update: I'm asked if there's a way to disable autosave. I believe you have to set a default for NSDocumentAutosaveOldDocumentDayThreshold, which will probably only autosave beyond a certain time threshold. If you can confirm or test, please ping me at erica at tuaw.

While this insta-delete, complete with jiggling icons, may be counterintuitive for longtime Mac users, it makes perfect sense to iPhone or iPad users where there's a one-to-one mapping between apps on the launcher screen and apps installed on the device. On other mobile platforms, that's not necessarily the case: both Android and Blackberry devices have the ability to hide or subset visible apps versus the full suite of installed programs.

The flip side of this strong linkage between installation/removal and visibility of MAS apps in Launchpad is that non-MAS/conventionally installed apps cannot be deleted from the Launchpad UI. If you don't want all that app clutter, the only default options are to move the space-wasting apps into Launchpad folders (laborious) or move the apps themselves out of the Applications folder in the Finder (boneheaded, and actually won't work, per commenters). Even resetting your Launchpad (as Erica noted last week) still includes all your apps in the launcher's pages.

There is another way, however, to blank out your Launchpad and start clean. Web developer Loren Segal points out the 'nuclear option' of deleting all the app records from the Launchpad database, which lets you select individual apps to include by dragging their icons onto the Launchpad dock icon (command-click to select multiple apps before dragging). He suggests backing up the relevant database file beforehand, in case of issues, and I concur.

[deletes the app records from Launchpad's database, and restarts the Dock process; you'll see your minimized windows pop back to the screen. Update: Loren posted a new version, as above, that fixes the folders issue.]

Blank Launchpad! You may notice that any folders previously in Launchpad will still be there, albeit vacant. To get rid of them, simply load at least one app into Launchpad, then drag the app into & out of the folder. It will 'evaporate' when it's empty.

The young guys over at HaiTeq have been running into issues with Launchpad updating after installing software that wasn't bought on the Mac App Store. Because of this, they've figured out a workaround to force Launchpad to refresh its data base.

Removing the database files from the user's Dock application support folder and restarting the Dock allows Mission Control and the Launchpad to re-build the database from scratch, updating the presentation with all the new applications.

Here are HaiTeq's steps, with a few modifications on my part for safety. Admittedly, if you are not comfortable at the command line, this is not the hack for you.

Launch Terminal (from /Applications/Utilities/Terminal).

Navigate to the Application Support folder in question (cd ~/Library/Application\ Support/Dock)

Open the folder (open .) and drag all the .db files to the trash.

Restart Dock (sudo killall Dock, followed by authentication)

I am not a Launchpad/Mission Control user and cannot verify these steps will reflect newly installed software. However, I did test them out for safety, and my Lion install is still working; my db file was instantly re-generated, and I did not find any harmful side-effects.

I was up late last night building a Mac App Store scraper. In the process I discovered how to browse the store in Safari. Without further ado, let me share the geek.

It turns out you can spoof curl with the Mac App Store user agent to access its data. You'll need to use Terminal for this trick, so if you're uncomfortable with the command line, it's sort of time to skip to the next post.

Since it doesn't come with an optical drive, giving MacBook Air buyers a DVD of the operating system wouldn't be very helpful. That's why Apple's lightest laptop comes with the USB Software Reinstall Drive -- a very small white USB drive. Sometimes USB flash drives are referred to as "Thumb Drives," but this one is more like the size of a baby's finger.

The USB stick that comes with the MacBook Air is the best way -- and in many situations, the only way -- to restore/reinstall your MacBook Air if something goes wrong. If you have the US$100 external USB SuperDrive, then you can try to use a DVD, but I found that my MacBook Air wouldn't even boot from my original Snow Leopard DVD. (I believe this is because the DVD's build of Snow Leopard is a lower version number than the Air originally shipped with, but I am not sure.)

Since my MacBook Air first arrived I have been afraid of losing the USB recovery drive. According to someone on the Apple Discussion Forums, Apple may be willing to provide you with a new one, free of charge, if you lose yours, but what I really wanted was a backup. (I have done the same thing with my Snow Leopard DVD when I bought it, just in case it was lost or damaged.) In this case, I wanted to duplicate it onto another USB drive.

I tried 'cloning' the Reinstall Drive using SuperDuper!, which completed without error, but after it was done, my MacBook Air would not boot with the new USB drive.

Apple created the drive so that when it is mounted by OS X, it appears as a DVD, not a USB drive. This means that it was not available for me to use as a "Restore" source in Disk Utility. I could not find any way to make a copy of the disk image from Disk Utility. (If one exists, I'd be happy to hear about it.)

That's when my GeekInstincts kicked in.

If Apple wanted me to treat it as a DVD drive, that's exactly what I would do. In the past I have backed up my OS X DVDs using the Terminal, and I wondered if the same thing would work here. (Spoiler alert! It did.)

Duplicating a CD or DVD the Unix way

Rather than using a GUI program such as Roxio Toast or Burn, we're going to use the Terminal. Why? Because unlike those two programs, the Unix way is free, simple, and "just works." Plus, you end up with a disk image, which you should be able to use to burn an actual DVD on just about any computer.

The steps are fairly simple:

Create an .iso file of the official Reinstall Drive

Mount the .iso file in Disk Utility

Mount a generic USB drive

Use the "restore" function in Disk Utility to copy the .iso file to the generic USB device.

Save the .iso file in case you lose the Reinstall Drive and your generic backup.

Note: you can do this same process with any CD/DVD and any Mac. In the past I have done it with Microsoft Office, iWork, and others. This article is addressing the MacBook Air specifically, but the same steps would work equally well for other media.

The Disclaimer

We are going to be using Terminal.app (found in the /Applications/Utilities/ folder in the Finder) to run a few commands. If you are not careful in the Terminal, you can do some serious damage. Then again, the same thing is true about a car. So, look both ways, stop if you aren't sure about something, and (whenever possible) copy & paste commands rather than typing them manually, to avoid typos.

The command we will be using is /bin/dd, which I suggest you think of as "Data Duplication." Wikipedia says that it probably originally meant "Data Description," and it is often jokingly referred to as "data destroyer" or other scary-sounding names.

Read slowly, take your time. There should be no real danger unless you are extremely careless. Don't proceed unless you know what you are doing and have verified your backups.

You should see something like "/dev/disk?s?" where the ?s are replaced by numbers. If all you get a blank line, something went wrong. Make sure the drive appears in Finder.

4) Still in Terminal, type/paste this line:

diskutil unmount "/Volumes/Mac OS X Install"

which should tell you "Volume Mac OS X Install on disk?s? unmounted" (again, where ? and ? will be numbers). This will unmount but not eject the drive.

5) READ this entire step, and make sure you understand it, before you do anything.

Now we will tell dd to:

a) read input from the "$DEVICE" named above. This is the "Input File" which is identified using if=/dev/disk?s? (where ? are numbers)

b) copy what you read (in step 'a') out to a new file. This is the "Output File" which is identified using of=WhateverYouWant.iso (I went with airinstall.iso for simplicity and clarity).

c) We also need to tell dd to use a Block Size of 2048 (this last part may not be 100% necessary, but I have seen it suggested and it is how I have done mine, and it worked).

If you put all of that together, it should look like this:

/bin/dd if="$DEVICE" of="$HOME/Desktop/airinstall.iso" bs=2048

WARNING: if, by some bizarre chance, you already have a file named "$HOME/Desktop/airinstall.iso" be sure to move or rename it before you enter that line. Otherwise it will be overwritten.

(The Output File does not have to be saved to the Desktop, I just chose that because it is a place most people will notice.)

If you see an error "dd: /dev/disk?s?: Resource busy" then the device did not unmount properly in step #4.

If you copied my "DEVICE=" line above in Step #3, you should be able to use "$DEVICE" in the 'dd' line to automatically fill in the proper device.

Note!

the 'dd' command may run for 20–30 minutes, or longer. Don't panic. Just go do something else for awhile.

nothing new will appear on the screen until 'dd' is finished.

When it is done you should see something like this:

3738954 0 records in
3738954 0 records out

The "records in" should equal the "records out" (although your number might not be the same as mine).

6) Assuming everything went as expected, you can now tell the computer to eject the Apple Reinstall Drive by entering this line in Terminal:

diskutil eject "$DEVICE"

It should tell you that the device was ejected. If so, it will be safe to physically disconnect the Apple Reinstall Drive from the USB port of your computer.

7) Open the .iso file in Disk Utility. If you used my /bin/dd line above, you can now enter:

open -a "Disk Utility" "$HOME/Desktop/airinstall.iso"

and Disk Utility will open and the .iso will appear in the left sidebar.

Note: we are now done with Terminal.app. You may quit it and switch over to Disk Utility for the next steps.

8) You should see airinstall.iso in the left side of Disk Utility window. If you look at the bottom of the window you will see it is not mounted. Click the "Open" button on the top toolbar to mount the .iso file.

NOTE: When you mount the .iso file, Finder will probably jump up and show you the window like an excited schoolchild. If that happens, just switch back to Disk Utility.

This is what Disk Utility will look like after you mount the .iso:

Note that the capacity it shown, and the open button is now a greyed out "Mount" button, and the "Eject" button is now available.

Here is Disk Utility showing my USB drive. A few important things to notice:

Make sure the drive is formatted as "Mac OS Extended" or "Mac OS Extended (Journaled)."

The "Name" of your drive isn't important. Notice mine is "USB_MOUNT" but the important thing is that I have it selected in Disk Utility.

10) We are now going to tell Disk Utility to "Restore" the .iso's "Mac OS X Install" to "USB_MOUNT" by doing three things:

a) click the "Restore" button (see red box below)

b) Control-Click ("right click") on the "Mac OS X Install" line, and select "Set as source" as shown here. You could also just drag the Mac OS X Install volume over to the Source: field in the right-hand pane.

c) Control-Click on the "Name" of your generic USB drive (mine is "USB_MOUNT") and choose "Set as destination." Again, you could alternatively drag-and-drop the volume icon into the blank Destination field on the right side, per the onscreen instructions.

11) When you are ready to restore, it should look something like this:

If everything looks correct, click the "Restore" button on the bottom right. Disk Utility will give you a "human readable" explanation of what it is about to do:

Read through it to make sure that you haven't accidentally swapped the Source and Destination fields. When you click "Erase" OS X will prompt you for your administrator password. Once you enter it, the restore process will begin.

This took 30 minutes on my MacBook Air, so it's a good time to take that Apple Software Reinstall Drive and put it somewhere safe. (I highly recommend putting it back in the box your MacBook Air came in. You kept the box, right?)

Once the Restore Process completes, Finder will most likely mount the generic USB drive.

Disk Utility will look like this:

Now we're ready to test it, so quit all of your applications, logout, and shutdown the computer.

The Proof is in the Booting

The only real test that matters is whether or not you can boot your MacBook Air with the generic USB drive.

After the computer id turned off, make sure that:

the official Apple Softwware Reinstall Drive is not connected to your MacBook Air

the generic USB drive is connected to the MacBook Air

Then power the computer on and press the Option/Alt key.

In a few moments you should a screen offering the option of booting from your hard drive or the USB drive. Choose the USB drive.

When it finishes booting, it will start into the "Install OS X" screens and ask you to select a language. Don't panic. Select a language, and then at the next screen you can exit out of the installer.

(If you want to set an Open Firmware Password, this would be a good time to do it, since you can't set it when booting off the internal drive, but if you do, remember that if you forget the password, a trip to the Apple Store is your only hope of recovering it.)

That's it

The USB drive won't work on any other computer, but it can add a little peace of mind to know that you have another copy of your restore drive in case you ever need it.