sleepimage file size I'm planning a clean install of my MacBook Pro with OS X 10.6 and I want to make a partition (among others) only for the sleepimage file.

Here's the problem: the partition's size.

I know that this file is exactly the same of my RAM amount: 4 GB.

However the Finder's "Show information" panel says that it's arount 4.3 GB! Which one do I have to trust to?

And if it isn't enough, I know that each partition retains a 10% of its size (even if it's tunable in a second moment with tunefs); so I'm able to use (by default) only up to 90% of it.

I'm not expert enough to know if the HFS+ journaled filesystem will place any additional (hidden) file, but I suppose that I'm on the right way… can you tell me something more?

I really appreciate any help you can provide.

The sleep image file gets created to store the contents of RAM, so you should be able to make things fit by checking the math carefully.

How OS X and iOS report storage capacity  - http://support.apple.com/kb/TS2419

So, once you've made sure you don't have errors in powers of 2, you can make a small allowance for the filesystem overhead and try using a partition to store this one file. You will want to also consider that the OS will take control of this file on a very low level and perhaps cause the file to be written to the root filesystem even if you take pains to properly mount the auxiliary filesystem. Also, since swap files get written to this same directory, your plan might cause unintended consequences, so be sure you have a good backup and can recover any file should the machine run out of space for /private/var/vm and freeze out whatever app you have running.


Macbook 2009 Memory Question I'm working on a MacBook (13-inch, Late 2009) 2.26 GHz Intel Core Duo.

I'm attempting to install two memory modules labelled 4GB DDRL-1600 SODIMM by Crucial (Memory Module A1/A2)

I'm unable to install two simultaneously. The modules (either one discounting a bad module) one of the pairs works correctly when paired with a 2GB 2RX8 PC3-10600S-999 (Memory Module B1,B2) by ADATA. Why would they work when paired but not simultaneously? The logic board supports up to 8 GB?

The combinations are written below.

B1+B2 = works
A1+B1 = works
A2+B1 = works
A1+B2 = works
A2+B2 = works
A1+A2 = doesn't work?

My goal is to determine if I need to return the memory modules.

Crucial own website says this memory is not compatible with your model Mac. I suppose this might be because officially your model Mac does not support 8 GB of memory.

The simplest explanation for your problem is the Mac adjusts the timing based on the the memory installed. Most likely the ADATA memory is slightly slower thus causing the Mac run the Crucial module at this reduced speed. When both Crucial modules are installed, this restriction is lifted, but this causes some other timing conflict that prevents the memory from working properly.

According the the manual for your Mac, the memory should meet the requirements given below. (The link to your manual came from this Apple website.)

Double Data Rate Small Outline Dual Inline Memory Module (DDR3) format
30 mm (1.18 inches)
204-pin
1 GB or 2 GB
PC3-8500 DDR3 SO-DIMM 1066 MHz Type RAM

Crucial recommends DDR3 PC3-8500 memory for your Mac. I realize this module is not 4GB.

From the image you posted, I assume the ADATA memory is PC3-10600.

You bought Crucial DDR3 PC3-12800 memory. This memory does not even appear on CRUCIAL® MEMORY FOR MAC® SYSTEMS COMPATIBILITY CHART.

According to this compatibility chart, you would want the CT2K4G3S1067M pair of modules.

A good table comparing the different modules can be found here.

  Note: I have aways been annoyed that the older slower memory is often more expensive that the newer faster memory.


How to remove Touchbar animations? On the 2016/2017 MacBook Pro's the Touchbar animations are slow. After a little while I've become used to the keyboard and Touchbar. But the one thing I would like to speed up is the transitions.

Say for instance you are playing music on Spotify while working. They you hit the media button to expand the view for full controls. It only takes a second... but it still takes a whole second. When you know what you want and you can navigate quickly the animation is agonising.

Is there a terminal command to remove Touchbar animations, forcing the new buttons to appear immediately?

Not a solution to the problem, but small tip to quickly change brightness and volume without waiting for full animation to expand or holding fn key to switch to the buttons.

Just quickly swipe across the icon in the direction you wan't to change (to the left - decrease value / to the right - increase)

or

You can tap&hold, and then swipe where you wanted (your finger should ended up being offset from where the knob is). In this case expanding animation will be played, but you save some time not needing to navigate to the knob or buttons


Which video player can play 1080p mkv on iPad Mini Retina? The iPad Mini Retina comes with the new A7 chip. However, playing back of a 1080p MKV is still sluggish using VLC. I'd like to know whether other paid video players are better in handling 1080p MKVs?

Some information about the MKV:

1920x1080, x264 10bit
AAC 5.1 720 kbps

Give AVPlayerHD a try. I can't say I've tested 10bit 1080p video on it with an iPad Mini Retina, but it used to work flawlessly for 10bit 720p video on an iPad 2. Since there's a big difference in specs between the two iPads, I don't think  you'll have issues playing your videos with that app.


Calendar no longer syncs with Exchange after upgrading to iOS 8 Since upgrading to iOS8, I've had constant problems with the Calendar app.  First it started only syncing to the iCloud, and ignored everything from Exchange.  I managed to stop this, and "delete all" entries from the Calendar, but no it isn't doing anything at all.  The + symbol to create a new event is grayed out.  I checked the settings, and Exchange is the default account.  How do I get this working again?

If you have not already tried it, deleting the Exchange account from the iDevice (and all of the associated contacts, calendars and email if any was being synced), and then recreating the account can sometimes fix a variety of errors. Of course, making sure you know all of the server names and passwords and other needed information to set up the account would be wise before deleting the account.


How to view certificate info without installing I have a certificate and/or private key file (pfx) on my OS X desktop.  I'd like to look at its information (CN, SAN, OU, thumbprint, etc) but when I double click on it, it attempts to install into my Keychain.  Once its in there, I can see the info and then delete it.

I would like to know if there is a way to "open" a certificate for viewing without having to install it into your Keychain.  Similar to how you can click on the padlock in Safari and see the cert info.

I'd prefer something native to OS X but maybe there are tools out there too?

I'm not sure if this was available in the OS you had at the time you wrote your question, but at least with OS X 10.11.6, if you select the .crt file in the Finder and press the spacebar, a Quick Look window will open and you can see all of that info in a nice display.  Works for .pfx files too.


"Connect to Server" option missing Running OSX Lion, I have no "connect to server" option listed in Finder > Go menu. Everything I've read about connecting to a Windows file share references that option. Why would it be missing and where did it go? I am trying to connect to a SMB share at work from my personal laptop, so there is no corporate policy file disabling that option on it. The network admin knows of no reason why it would be missing.

I hope someone can help with this.

Chad,
Thanks for the link. Petrock had the solution. Here it is:

I used the free Pref Setter app to edit the plist file.

  You probably used one of those "set hidden finder features"
  apps/utils, didn't you... naughty person you is... If you open up
  ~/Library/Preferences/com.apple.finder.plist with Property List Editor
  and see an entry for "ProhibitConnectTo", then thats the problem. Set
  it to false and save the changes. Then Control-Option-Click on the
  Finder icon in the dock and select Relaunch. When the Finder comes
  back up, Connect To should be available again.


Is it possible to make a mouse accelerate like it did in Windows? 15 year Windows guy here, slowly going full Mac on everything and enjoying it.

But there's one thing that's killing me: the USB mouse acceleration curve in Snow Leopard drives me crazy. I've looked at utilities that claim to change it, but I haven't found anything that works (thanks Apple for removing the mouse acceleration curve function). I really want my mouse to move like it did in Windows.

What I have discovered is that different mice seem to have slightly different acceleration (or I'm going insane). I use a cheap Dell optical mouse at work that's fairly similar to what I'm used to in Windows. But my Razer Imperator at home, despite costing a fortune, moves like molasses through OS X.

I've tried the Magic Mouse and Magic Trackpad and have been unsatisfied with both.

Is this actually an issue? I may be very well be imagining it. Have any other ex-Windows guys experienced this?

No, unless you buy a specific mouse

The option to define custom mouse acceleration curves was present in OS X 10.4, but apple simplified it in 10.5, and removed it entirely in 10.6.

Mouse Curve is a supposedly forthcoming pref-pane that completely replaces the OS X mouse HID kext. However, development is really slow, or stalled.

Personally, I have poked about a bit in the kernel myself, but am unfamiliar with kernel programming. Fixing the mouse acceleration on OS X will at minimum require a custom kext, which is non-trivial to code.

The option that is out there is to buy a Microsoft mouse, and use it on OS X. Microsoft has released custom drivers for their mice that mimic the mouse behavior on windows.

Essentially, the windows "Enhance Pointer Precision" option applies linear velocity-based acceleration to the mouse movements, e.g. the distance moved is proportional to the speed the mouse moves. Think of it as basically having the DPI of the mouse inversely proportional to the mouse's speed.

OS X on the other hand, has a stepped acceleration curve, where the mouse moves at one DPI when slow, and another when moved faster then a threshold.

There are pref-panes that let you disable OS X's acceleration curve, but none that allow you to substitute windows.

As far as I can tell (and this is opinion), this curve is optimized for trackpads. In my opinion, it is more then useless for mice (using a mac mouse actually damaged my mousing efficacy on windows, which really affects my work (CAD Stuff)).

Personally, I have entirely dispensed with the idea of using a mouse on OS X, and ust bought a Magic Trackpad.


How to install an old version of Opera? I've recently upgraded my MacBook Pro from 10.8.5 to 10.10.5 and

a) I want to install an older version of Opera (version 40)

b) I want to eliminate the auto update issue.

Issues:

I tried downgrading Opera, but anytime I install an older version it autoupdates to the latest version without my consent.
I tried with an old .dmg I had saved, however the OSX gives me this message when I click on it:

If I let the system complete the verification I end up with the latest version of Opera. If I switch off the internet the process stops and I can't install a simple .dmg (it's as if OSX/Apple demands users to install only the software they expect/approve of).

Any solution please?

There are a few problems to consider here:

The screenshot in the question doesn't show the verification of the DMG on mount but the verification on application launch. Mounting a disk image is possible without internet connection.

You need the actual application or the full installer
Like many vendors you may end up with a tiny download that is only an installer stub that pulls in the actual installation data at runtime.
This can be circumvented by copying an old version of a fully installed Opera from a backup. The application is self-contained and will create all necesary support files on the fly when run.
Or for a fresh installation: download the full installer DMG from Opera's servers:
40.0.2308.90. (kudos to klanomath)
That gives you a drag and drop install from a DMG.
The verify process for newly installed applications on macOS is misleading us.
Obviously, parts of an application package are already executed while we all think macOS blocks all execution until the verification process is finished.
In this case Opera.app/Contents/MacOS/opera_autoupdate is run and auto-updates to the latest version while we still see the operating system verifying the application bundle.
The auto-update can be prevented

3.1 by moving/deleting/disabling the binary above – before the first launch. (Giving you "Checking for updates…" under "About Opera" never finishing, otherwise it launches and behaves fine)
3.2 by blocking the auto-update-server via /etc/hosts – (untested: 127.0.0.1 autoupdate.geo.opera.com ?)
3.3 by setting a system-wide proxy or personal firewall that blocks connections to Opera's update servers (only). (Both 3.2 and 3.3 will give you "An error occurred while checking for updates" under "About Opera")
3.4 by launching Opera from the commandline with the switch --check-for-update-interval=0. (Cleanest solution but you need to do this every time or create your own launcher for it.)

Since Opera seems to not have an option in the graphical settings panes to set auto update intervals: option 3.1 seems to be the easiest way to go.

This is for more recent versions of Opera. On an older version the official guidelines might still apply: Change auto-update settings.

Finally: if an autoupdate already has taken place: Opera keeps the last two binaries downloaded in Opera.app/Contents/Versions. Simply delete the version you do not want in there before re-launching the application again.


Will deleting/removing some system processes/ .plist files screw up my Mac? I am thinking of deleting some contents from /usr/libexec/ , I don't use AirPlay nor AirPort so if I delete these two processes will it again screw up my mac the processes are AirPlayXPCHelper and airportd

I don't even use Safari sync nor iCloud so I am thinking of deleting these .plist files /System/Library/LaunchAgents/com.apple.SafariCloudHistoryPushAgent.plist - 'com.apple.SafariCloudHistoryPushAgent'

What happened previously Accidentally deleted a system framework, macOS screwed! while messing with the OS

I am also thinking of running these commands to tweak my Mac

#!/bin/bash

# IMPORTANT: You will need to disable SIP aka Rootless in order to fully execute this script, you can reenable it after.
# WARNING: It might disable things that you may not like. Please double check the services in the TODISABLE vars.

# Get active services: launchctl list | grep -v "\-\t0"
# Find a service: grep -lR [service] /System/Library/Launch* /Library/Launch* ~/Library/LaunchAgents

# Agents to disable
TODISABLE=('com.apple.security.keychainsyncingoveridsproxy' 'com.apple.personad' 'com.apple.passd' 'com.apple.screensharing.MessagesAgent' 'com.apple.CommCenter-osx' 'com.apple.Maps.mapspushd' 'com.apple.Maps.pushdaemon' 'com.apple.photoanalysisd' 'com.apple.telephonyutilities.callservicesd' 'com.apple.AirPlayUIAgent' 'com.apple.AirPortBaseStationAgent' 'com.apple.CalendarAgent' 'com.apple.DictationIM' 'com.apple.iCloudUserNotifications' 'com.apple.familycircled' 'com.apple.familycontrols.useragent' 'com.apple.familynotificationd' 'com.apple.gamed' 'com.apple.icloud.findmydeviced.findmydevice-user-agent' 'com.apple.icloud.fmfd' 'com.apple.imagent' 'com.apple.cloudfamilyrestrictionsd-mac' 'com.apple.cloudpaird' 'com.apple.cloudphotosd' 'com.apple.DictationIM' 'com.apple.assistant_service' 'com.apple.CallHistorySyncHelper' 'com.apple.CallHistoryPluginHelper' 'com.apple.AOSPushRelay' 'com.apple.IMLoggingAgent' 'com.apple.geodMachServiceBridge' 'com.apple.syncdefaultsd' 'com.apple.security.cloudkeychainproxy3' 'com.apple.security.idskeychainsyncingproxy' 'com.apple.security.keychain-circle-notification' 'com.apple.sharingd' 'com.apple.appleseed.seedusaged' 'com.apple.cloudd' 'com.apple.assistantd' 'com.apple.parentalcontrols.check' 'com.apple.parsecd' 'com.apple.identityservicesd')

for agent in "${TODISABLE[@]}"
do
    {
        sudo launchctl unload -w /System/Library/LaunchAgents/${agent}.plist
        launchctl unload -w /System/Library/LaunchAgents/${agent}.plist
    } &> /dev/null
    sudo mv /System/Library/LaunchAgents/${agent}.plist /System/Library/LaunchAgents/${agent}.plist.bak
    echo "[OK] Agent ${agent} disabled"
done

# Daemons to disable
TODISABLE=('com.apple.netbiosd' 'com.apple.preferences.timezone.admintool' 'com.apple.preferences.timezone.auto' 'com.apple.remotepairtool' 'com.apple.rpmuxd' 'com.apple.security.FDERecoveryAgent' 'com.apple.icloud.findmydeviced' 'com.apple.findmymacmessenger' 'com.apple.familycontrols' 'com.apple.findmymac' 'com.apple.SubmitDiagInfo' 'com.apple.screensharing' 'com.apple.appleseed.fbahelperd' 'com.apple.apsd' 'com.apple.AOSNotificationOSX' 'com.apple.FileSyncAgent.sshd' 'com.apple.ManagedClient.cloudconfigurationd' 'com.apple.ManagedClient.enroll' 'com.apple.ManagedClient' 'com.apple.ManagedClient.startup' 'com.apple.iCloudStats' 'com.apple.locationd' 'com.apple.mbicloudsetupd' 'com.apple.laterscheduler' 'com.apple.awacsd' 'com.apple.eapolcfg_auth' 'com.apple.familycontrols')

for daemon in "${TODISABLE[@]}"
do
    {
        sudo launchctl unload -w /System/Library/LaunchDaemons/${daemon}.plist
        launchctl unload -w /System/Library/LaunchDaemons/${daemon}.plist
    } &> /dev/null
    sudo mv /System/Library/LaunchDaemons/${daemon}.plist /System/Library/LaunchDaemons/${daemon}.plist.bak
    echo "[OK] Daemon ${daemon} disabled"
done

Be careful!

Deleting the plist files and disabling them are two different things.

Those plists you mentioned in your block quote are (only imho) relatively save to disable on Sierra when SIP is disabled. SIP should probably be re-eanbled after you have finished tweaking your system.

What will be disabled is at first relatively easy to discern when just looking at the names of the culprits. But that can sometimes have quite unwelcome side-effects or unintended consequences.

These background processes are notoriously badly documented.
For example: disabling AiplayXPCHelper; that seems wholly superfluous but once disabled iTunes might refuse to even start. Gaining RAM and a few cycles from disabling one process might also be offset by many status and even error messages now written into your logs because certain Apple services try to communicate with others that are presumed to be 'there' but aren't.

A good number of those processes are frankly just absolutely essential and needed for a system to run properly at all. Some can be disabled. So, yes, you can screw up your mac. That last sentence is important.

How to approach disabling features that seem unnecessary or are decidedly unwanted was described for example here.

Have I said be careful yet? You have been warned.

Document your steps. Proceed slowly. Backup even more frequently than before.
Be sure you are able to retrace your steps. Keep two different backups and a bootable installer handy.

Therefore: deleting those plist files seems more thorough than just disabling them. Any space gained on disk is surely not worth it. But disabling is just so much easier to revert in case something goes wrong.

After reminding you to be careful once more: just do not delete things from /usr/libexec !


Apple Detecting Jailbreak on a NOT jailbroken iPhone I recently received a notification that took up the whole screen on my iphone which says that I have breached the Apple terms and conditions for jailbreaking my iphone.

However, I am pretty sure that I haven't done any jail breaking to it and it is a definitely a new piece of hardware since I bought it directly from the telco with the box and wraps.

What could be the reason for this happening and what should I do? It has been working fine for a year or so, till this message pop up recently.

That notification could have come from any app.  Check under your settings which apps you have got that you allow notifications from.  I am not aware of any official method for Apple to send these out, and unless there was some sort of corrective action or advice attached I can't see the point in you receiving it either.  This is almost impossible to provide a real answer to, but my first thoughts are either a prank or compromised notification through one of your existing apps.

If you receive it again, take a screen shot - hold down your home button, then tap the power button - the screen will flash white and the picture will appear in your camera roll.


Any way to map extra mouse buttons to keyboard shortcuts? My mouse has two other buttons which I think are referred to as button 4 and 5. Is there any way to configure these to trigger a keyboard shortcut like option delete for adobe premiere?

While not perfect (can't make application specific macros, and doesn't detect every button on my mouse) https://www.usboverdrive.com does exactly what I want and can trigger keyboard shortcuts with the mouse buttons I wanted to use.


Are there special boolean search operations (AND,OR, NOT) for iOS mail app? I got like 11000 emails available through the iOS mail app, and single keyword search no longer works for me. I would like to exclude specific words, like in google: (food -fast).

Are there special boolean operations or shortcuts availble to be entered into the iOS mail app?

If you search using Spotlight (from the Home screen), you can use to: and from: qualifiers, as well as flag and unread status.

From Apple's iOS: Understanding Spotlight Search page:

  Examples:

  Flagged june 2013

  Searches for all flagged messages from june 2013, as well as for messages containing these words
  Unread last week from:@icloud.com

  Searches all unread messages from last week where the sender's email ends with @icloud.com, as well as messages containing these words
  Vip read yesterday

  Searches all read messages from contacts marked as VIPs, as well as messages containing these words
  to:appleseed monday

  Searches all messages sent on Monday to a contact named "Appleseed", or an email address starting with appleseed, as well as messages containing these words

Note that these examples mention "messages containing these words". A note above the examples states that to search message bodies, you must use Mail's search function, not Spotlight, but these examples are for Spotlight. After testing, it appears these work in Mail's search field as well as Spotlight.

In addition to the above, you can use has:attachment to limit to messages containing attachments, and Mail appears to search within attachments.


Disable the Dock in all but one Desktop/Space only On My iMac I usually have several desktops that I use for separate things.
While I prefer to have the Dock on my main space to access apps easier, I much prefer to have the Dock hide on all other spaces, except for the main one.
I know, that I can just do Option-Command -D to hide/unhide the dock whenever, but is there a way, to have different Dock settings in different spaces?

I know, that I can just do Option-Command -D to hide/unhide the dock whenever, but is there a way, to have different Dock settings in different spaces?

No, the preferences of the Dock are global between Desktops/Spaces, however, there is a programatic way to automate the toggling of the autohide preference of the Dock as you switch between Desktops/Spaces.
This requires an application to be memory resident and able to respond to the target event.
As an example, you could roll your own in Xcode, or use any third-party application capable of responding to a Desktop/Space changed event, determine which Desktop/Space you are on, and then toggle the autohide preference of the Dock to hide/show it based on the conditions, effectively pressing the ⌥⌘D keyboard shortcut programmatically to avoid doing it manually.

With that said, I'll offer you a way that works for me and utilizes a free third-party application named Hammerspoon, along with using the free third-party Hammerspoon module hs._asm.undocumented.spaces to have access to the undocumented Spaces API.
Some Lua code, which is what Hammerspoon uses, along with some AppleScript code.
The example Lua code and example AppleScript code, shown further below, was tested under macOS Catalina and macOS Big Sur with Language & Region settings in System Preferences set to English (US) — Primary and worked for me without issue1.

1  Assumes all necessary and appropriate setting in System Preferences > Security & Privacy > Privacy have been set/addressed as needed.

In addition to Hammerspoon, the third-party Hammerspoon module hs._asm.undocumented.spaces to have access to the undocumented Spaces API, the Lua code and AppleScript code, as is and provided further below, all necessary Security & Privacy settings for operational control, one preference setting in particular is required to be unchecked in System Preferences > Mission Control:

[ ] Automatically rearrange Spaces based on most recent use

This is of course to keep the main working Desktop/Space as the first one in the list, thus having a numeric ID of 1, as ascertained by the module that provides access to the undocumented Spaces API.
This also assumes the Apple default keyboard shortcut to hide/show the Dock is in play.

Option-Command-D: Show or hide the Dock.

    From: Mac keyboard shortcuts
Also, as coded, only a single display/monitor was used. Additional coding may/would be required for a multi display/monitor arrangement. However, not being able to test at this time, it is outside the scope of the solution offered herein.

Note that the download and install instructions assume Safari and default preference [√] Open “safe” files after downloading checked.

Download Hammerspoon

https://github.com/Hammerspoon/hammerspoon/releases/latest

Click the Hammerspoon-n.n.nn.zip link.

Download hs._asm.undocumented.spaces

https://github.com/asmagill/hs._asm.undocumented.spaces

Click the Code button and click Download ZIP

Note: During the initial install and setup of Hammerspoon and the hs._asm.undocumented.spaces module you will be presented with a number of Security & Privacy related dialog boxes and notifications to which you need to reply with an affirmative type response, e.g., [Allow], [Open], [OK], [Allow Anyway]. If the choice is [Move to Trash] or [Cancel] choose [Cancel], or if the choice is [Open], [Move to Trash], [Cancel] choose [Open]!

Install Hammerspoon

Open the Downloads folder and drag and drop the Hammerspoon application bundle into Applications.

Before you open Hammerspoon, add it to: System Preferences > Security & Privacy > Privacy > Accessibility

Hint: Leave System Preferences open and unlocked as you will need it again shortly.

Open Hammerspoon from Applications or Spotlight, then:
From the Hammerspoon menu (hammer icon) on the menu bar, click it, then click Preferences…, and set them as follows:
Hammerspoon Preferences
Behavior:

[√] Launch Hammerspoon at login
[√] Check for updates
[ ] Show dock icon
[√] Show menu icon
[ ] Keep Console window on top
[ ]Send crash data (requires restart)

Accessibility: Accessibility is enabled. Your all set!
         Enable Accessibility (Should be grayed out.)
Close Hammerspoon Preferences.

Install the hs._asm.undocumented.spaces module.
Open: Downloads
Open the hs._asm.undocumented.spaces-master folder to verify the name of the included spaces-vX.Y.tar.gz file against the commands used in the next install step in Terminal.
Open Terminal and run the following commands:

The current version of spaces-vX.Y.tar.gz, as of the day of this answer, is: spaces-v0.2.1.1-universal.tar.gz
cd ~/.hammerspoon
tar -xzf ~/Downloads/hs._asm.undocumented.spaces-master/spaces-v0.2.1.1-universal.tar.gz

Close: Terminal (Assumes no error from previous command.)

Adding the Lua code to Hammerspoon
Open the Hammerspoon configuration file by clicking the Open Config command from the Hammerspoon menu (hammer icon) on the menu bar.
Add the example Lua code, from below, to the init.lua configuration file and save the document, then close it.

Important Steps
In this next step the init.lua configuration file will get reloaded from the Reload Config command on the Hammerspoon menu (hammer icon) on the menu bar.
Note: The Reload Config command will fail because the internal.so module cannot be verified.
Click: Cancel
Then on the System Preferences > Security & Privacy > Privacy > General pane:

“internal.so” was blocked from use because it is not from an identified developer.

Click: Allow Anyway
Close the Hammerspoon Console window and the Hammerspoon notification.
Again, click the Reload Config command on the Hammerspoon menu (hammer icon) on the menu bar.
It should not error this time, but click Open to the message:

macOS cannot verify the developer of “internal.so”. Are you sure you want to open it?

Phew! That's almost it! Your almost done and ready to go! Only one more security step to address when you switch spaces for the first time.

“Hammerspoon” wants access to control “System Events”. Allowing control will provide access to documents and data in “System Events”, and to perform actions within that app.Hammerspoon needs to send events to automate applications.

Click: OK

Yeah! Now you are done and ready to change Desktop/Space and the Dock will then automatically hide on all Desktops/Spaces except the main one.

Note: The example Lua code for Hammerspoon's init.lua configuration file is presented in two sections, the first is just the necessary Lua code and the second is commented code with URLs to each relevant Hammerspoon API and the hs.asm.undocumented.spaces module.
Example Lua code:
spaces = require("hs._asm.undocumented.spaces")

function spaceHasChanged()
    local asCommand = "tell application \"System Events\" to return autohide of dock preferences"
    local ok, theDockIsHidden = hs.osascript.applescript(asCommand)
    if ok then
        local spaceNumericID = spaces.activeSpace()
        if spaceNumericID == 1 and theDockIsHidden then
            hs.eventtap.keyStroke({"cmd", "alt"}, "d")
        elseif spaceNumericID > 1 and not theDockIsHidden then
            hs.eventtap.keyStroke({"cmd", "alt"}, "d")
            local asFile = "/.hammerspoon/Scripts/FSAWWODS.applescript"
            local ok, status = hs.osascript.applescriptFromFile(os.getenv("HOME") .. asFile)
            if not ok then
                local msg = "An error occurred running the FSAWWODS.applescript script."
                hs.notify.new({title="Hammerspoon", informativeText=msg}):send()
            end
        elseif spaceNumericID == "" or spaceNumericID == nil then
            local msg = "An error occurred getting the active space ID! Review Console log."
            hs.notify.new({title="Hammerspoon", informativeText=msg}):send()
        end
    else
        local msg = "An error occurred getting the value of autohide for the Dock."
        hs.notify.new({title="Hammerspoon", informativeText=msg}):send()
    end
end

spaceWatcher = hs.spaces.watcher.new(spaceHasChanged)
spaceWatcher:start()
-- spaceWatcher:stop()

    -- The multi-line commented section below is the
    -- commented code above, with URLs to each relevant
    -- Hammerspoon API and asm.undocumented.spaces module.
    -- This is provided for users new to Hammerspoon
    -- to help the user understand what the code is doing.

 --[[

    -- This module provides Hammerspoon with access to the undocumented Spaces API.
    -- https://github.com/asmagill/hs._asm.undocumented.spaces

spaces = require("hs._asm.undocumented.spaces")

    -- User created function for use with 'hs.spaces.watcher' submodule.
    -- Each time the Desktop/Space changes this function is called.
    -- https://www.hammerspoon.org/docs/hs.spaces.watcher.html

function spaceHasChanged()

        -- Use AppleScript to get the value of the 'autohide' preference of the Dock.
        -- https://www.hammerspoon.org/docs/hs.osascript.html#applescript

    local asCommand = "tell application \"System Events\" to return autohide of dock preferences"
    local ok, theDockIsHidden = hs.osascript.applescript(asCommand)

    if ok then

            -- The AppleScript command executed without error.

            -- Get the numeric ID of the currently active space.
            -- https://github.com/asmagill/hs._asm.undocumented.spaces

        local spaceNumericID = spaces.activeSpace()

            -- Toggle Hide/Show of the Dock as required.

        if spaceNumericID == 1 and theDockIsHidden then

                -- Press ⌥⌘D to unhide the Dock.
                -- https://www.hammerspoon.org/docs/hs.eventtap.html#keyStroke

            hs.eventtap.keyStroke({"cmd", "alt"}, "d")

        elseif spaceNumericID > 1 and not theDockIsHidden then

                -- Press ⌥⌘D to hide the Dock.
                -- https://www.hammerspoon.org/docs/hs.eventtap.html#keyStroke

            hs.eventtap.keyStroke({"cmd", "alt"}, "d")

                -- Use AppleScript to work around an apps window that does not
                -- go to its own Desktop/Space when placed in full screen view.
                -- This is included and coded for VLC media player. Other apps
                -- that fall into this category will need to have their own
                -- code added to ~.hammerspoon/Scripts/FSAWWODS.applescript
                --https://www.hammerspoon.org/docs/hs.osascript.html#applescriptFromFile

            local asFile = "/.hammerspoon/Scripts/FSAWWODS.applescript"
            local ok, status = hs.osascript.applescriptFromFile(os.getenv("HOME") .. asFile)

            if not ok then

                    -- An error occurred running the FSAWWODS.applescript file.
                    -- https://www.hammerspoon.org/docs/hs.notify.html#new
                    -- https://www.hammerspoon.org/docs/hs.notify.html#send

                local msg = "An error occurred running the FSAWWODS.applescript script."
                hs.notify.new({title="Hammerspoon", informativeText=msg}):send()

            end

        elseif spaceNumericID == "" or spaceNumericID == nil then

                -- An error occurred getting the active space ID.
                -- https://www.hammerspoon.org/docs/hs.notify.html#new
                -- https://www.hammerspoon.org/docs/hs.notify.html#send

            local msg = "An error occurred getting the active space ID! Review Console log."
            hs.notify.new({title="Hammerspoon", informativeText=msg}):send()

        end

    else

            -- An error occurred getting the value of autohide for the Dock.
            -- https://www.hammerspoon.org/docs/hs.notify.html#new
            -- https://www.hammerspoon.org/docs/hs.notify.html#send

        local msg = "An error occurred getting the value of autohide for the Dock."
        hs.notify.new({title="Hammerspoon", informativeText=msg}):send()

    end

end

    -- Each time the Desktop/Space changes, run the user created function.
    -- https://www.hammerspoon.org/docs/hs.spaces.watcher.html

spaceWatcher = hs.spaces.watcher.new(spaceHasChanged)

    -- Start the 'spaceWatcher'. The commented 'spaceWatcher:stop()' line is there for
    -- convenience to uncomment/comment it and 'spaceWatcher:start()' and reload the
    -- config file from the Reload Config command from the Hammer icon on the menu bar.

spaceWatcher:start()
-- spaceWatcher:stop()

--]]

Note: Because of the comments the Lua code is long. It ends with --]], so make sure you highlight all of it when copy and paste it to the init.lua configuration file.
Note: This example Lua code has been updated to include additional Lua code used in conjunction with the example AppleScript code in the Update to Original Answer section below.

Update to Original Answer
This update is to address an issue found after posting the original answer.
Applications whose window when placed in fullscreen view and is not moved to its own Desktop/Space and hides the Dock will cause the Lua code as originally written to show the Dock, the opposite of what's wanted.
The application in question is VLC media player. There may also be other applications that do the same thing and additional code can be added to accommodate as/when needed.
Note that if you do not use VLC media player you should still do this so the framework is in place to accommodate any application that will require such a workaround.
I have updated the original Lua code I posted, and you will need to copy and paste it into the init.lua configuration file, replacing the original code in your init.lua configuration file with it and save it, but do not reload it until the next steps are taken. Use the information in the Adding the Lua code to Hammerspoon section above to add the updated Lua code.
Adding the AppleScript script to Hammerspoon
In Terminal:
mkdir -p ~/.hammerspoon/Scripts
touch ~/.hammerspoon/Scripts/FSAWWODS.applescript
open ~/.hammerspoon/Scripts/FSAWWODS.applescript

Close: Terminal (Assumes no error from previous command.)

In Script Editor:
Add the example AppleScript code, shown below, to the opened FSAWWODS.applescript document, then save it, and close the document.
Close: Script Editor
With that done, you can now click the Reload Config command on the Hammerspoon menu (hammer icon) on the menu bar, as the update is completed.

Example AppleScript code:
--  #
--  # NOTE: Hammerspoon does not allow the use of the
--  #       AppleScript line continuation character.
--  #       Therefore code must be written in long form.
--  #       It also doesn't like the use of some characters
--  #       such as symbols for modifier keys and others
--  #       in comments and possibly in code as well.
--  #
--  # Name: FSAWWODS.applescript
--  #
--  #       Full Screen Application Window Without Own Desktop/Space
--  #
--  # Purpose:
--  #
--  # The purpose of this script is to workaround an issue in
--  # hiding the Dock when an application is in fullscreen view
--  # and is not moved to its own separate Desktop/Space.
--  #
--  # Currently this script is configured for the VLC media player.
--  # Each application that has this issue will need its own code.
--  # The code will be different based on the specific application.
--  #
--  # The issue with VLC is that when in fullscreen view it hides
--  # the Dock thus causing the Lua code to unhide it. I suspect
--  # other apps that do the same thing will need to press the
--  # Option-Command-D keyboard shortcut again in order to counter
--  # the Lua code from unhiding it in similar scenarios.
--  #
--  # VLC is only app I have encountered this issue with so far.
--  #

tell application "System Events"
    set |fmAppName| to name of process 1 whose frontmost = true
end tell

if |fmAppName| is "VLC" then
    tell application "System Events" to tell process "VLC"
        tell menu item "Fullscreen" of menu 1 of menu bar item "Video" of menu bar 1
            set isEnabled to value of attribute "AXEnabled"
            set isFullscreen to value of attribute "AXMenuItemMarkChar"
        end tell
        if isEnabled and isFullscreen is not missing value then
            keystroke "d" using {option down, command down}
        end if
    end tell
else if |fmAppName| is "NameOfApp" then
    --  # Add additional 'else if' as needed.
    --  # Code for NameOfApp app goes here.
end if

Notes:
Just a reminder that this update is only applicable to applications whose window when placed in fullscreen view is not moved to its own Desktop/Space and also hides the Dock.
Because of this particular issue, the Dock will appear to bounce as the value of its autohide preference is toggled by the extra ⌥⌘D needed in this instance. It is still better than having to manually press ⌥⌘D all the time.


Computer modern font for OSX I need it to make posters with Scribus.
I got the hint that use the Computer Modern Font.
However, I am not sure if the newest OSX has it, where could I get it from?

OS X has never included Computer Modern as standard, only as part of the X11 system. The font was originally created by Donald Knuth using metafont so that he had a good font for his typesetting system, Tex, that he wrote to typeset his books on programming.

The modern versions were created to provide a good quality font for the X11/Tex project.

The Computer Modern home page is here: http://canopus.iacp.dvo.ru/~panov/cm-unicode/ Note that these are the version with the "Blue Sky" font hinting that almost everyone uses these days rather than the Knuth originals.

You will want the "otf" (Open Type Font) file which at the time of writing is ftp://canopus.iacp.dvo.ru/pub/Font/cm_unicode/cm-unicode-0.6.3a-otf.tar.gz

If you open the application Font Book you can have a look at the fonts installed on the System and install new ones using drag and drop.

On a final note, if you arrive at this answer and are going to be doing serious typesetting with Computer Modern you may wish to install the entire American Mathematical Society AMSFonts package available here - it's even packed as a TEXMF directory structure if that is of use to you. Otherwise it contains Postscript fonts well down in the folder hierarchy that can be easily installed on a Mac. It includes other useful fonts and extensions to the basic Computer Modern set. All are free under the SIL Font License.


How to upgrade an iPad without losing data? What do you mean "how to upgrade an iPad"? You plug it in, start iTunes, click Upgrade and that's it!

That's what I thought before starting the process. After all, it's Apple we're talking about, right?

Not quite.

I am trying to upgrade my father's iPad 1 to iOS 5 using a brand new Windows 7 profile on my laptop. I plugged the iPad in, and it complained because the relevant Windows service was down.

An UAC elevation and a trip to the services interface later, iTunes informed me that if I didn't transfer purchases to my computer I'd lose them, and asked me if I wanted to continue. Continue to what, upgrading or transferring?

A cancel and a right click on iPad → Transfer purchases later, iTunes told me that the upgrade would wipe the iPad completely clean and that I'd need to sync everything beforehand, and asked me if I wanted to continue... doing what? Upgrading while losing all the data or doing syncronization?

Now I'm stumped. The iPad "tabs" show all sync options are disabled. When I enable them, iTunes warns me that by doing that the iPad content will be replaced by the computer content, which would be absolutely nothing.

So, here's my apparently simple question. I'm really surprised I have to ask...

How can I upgrade an iPad (or an iPod) to a newer version of iOS using a brand new computer without losing data in the process?

Is a backup what I want perhaps? Would a backup include the current version of iOS, making the restoring process undo the upgrade in the first place?

First, make sure that iTunes is signed into the iPad owner's Apple account. It is best if this is done in a separate login account on the computer so you do not loose any of your saved apps and backed up data.

Then from there once you plug it in to a full backup to the computer, no upgrading yet! Always do a full backup before an upgrade. Once backed up go and do the upgrade. This will wipe all data on the iPad! Once the update is installed, it will then restore all the prior apps, data, music, movies, pictures and books the tablet.

After that, everything should be golden.

(This is based on my experience upgrading an iPhone 4 from iOS 4 to 5.)


How do I set an icon for a directory via the CLI? Possible Duplicate:
  Changing a file or folder icon using the Terminal

This is a continuation of this thread from Super User. The question is how to set an icon on a directory. At first I was trying cp -R, which did copy the directory with the icon, but it also copied every file and subdirectory in the folder. Then Keith Thompson suggested that one of the invisible files inside a directory might be responsible for the icon (because cp -R would preserve those/bring them with the copy) so I tried copying the 'Icon?' invisible file from a folder with the desired icon to new directory (newly created with mkdir) but that didn't work. He said to ask here, because this is more geared towards Mac- and UNIX-based questions. In that last post, he also suggested the .DS_STORE file  (which I've seen, but I think stores which files to display) but I may try copying that into a new folder too...

Empty directory is created
No invisible files
Regular files are put into the folder, '.DS_STORE' appears.
Icon is set manually on the folder, the 'Icon?' file appears.

Does anyone know how to set an icon on a directory through the shell?

You can create a shell script and name it something like mkdir_WithIconFrom

#!/bin/sh
mkdir $1
cp $2/Icon\r $1
SetFile -a C $1

This will create a directory at the first path you specify on the command line with the icon from the existing directory whose path you specify second on the command line, assuming the target directory has a custom icon.


How do I improve my performance of my MBP (2009) after upgrading to 10.8.2 I'm relatively a novice when it comes to computers. I recently upgraded my MBP to the new OS X 10.8.2 and noticed that it's running much slower now.  I purchased this laptop in the summer of 2009. Here are the basic specs:

Macbook Pro 13-inch, (mid-2009)
Processor 2.26 GHz Intel Core 2 Duo
Memory 2 GB 1067 MHz DDR3
Graphics NVIDIA GeForce 9400M 256 MB
SATA Disk 160GB

Any recommendations on how to boost its performance would be greatly appreciated. I would love to avoid purchasing a new laptop, unless needed.

I have the same MacBook Pro model.

Upgrading your RAM to 8 GB will help a lot, as the others suggested. You might also look into adding an SSD using something like the Data Doubler by Other World Computing (macsales.com).

Then you could do something cool like this: http://reviews.cnet.com/8301-13727_7-57550128-263/how-to-make-a-custom-corestorage-drive-in-os-x/


iOS Developer Contracts Missing After watching the WWDC 13' announcement of iOS 7 I wanted to download and install the beta release of the new OS using my paid developer account. I logged on to iTunesConnect and was greeted with a message telling me I would need to review and agree to the new Developer Agreement and Paid Applications agreement before I can make any app updates. Additionally, my subscription expires on JULY 19th (about 39 days from now). I don't want to (and can't afford to) renew it until it's actually close to expiring.

For whatever reason, I cannot seem to find where I'm supposed to go to can accept the updated documents. The "Contracts, Tax and Billing" section only gives me the option to view the current documents in place, not renew or review the revised copies. Additionally, the "Member Center" simply wines at me to renew my subscription, not telling me where the agreement documents are.

If anyone else is having this issue, please let me know how you got through it. I've contacted Apple Support and I'll post what I hear from them.

Since Apple has a support department to help paid developers, have you made use of that support?

https://developer.apple.com/support/technical/

From your description, it's likely you are not making a mistake and the problem is on the server end, but it could also be something where a warning is being dismissed as whining and the information is there for you to assemble and act on.


How to select multiple tabs in Mac Safari Having used Google Chrome for a long time, I've previously taken it for granted that multiple tabs in a given browser window can be selected, either one at a time (Ctrl-click) or in a contiguous range (Shift-click). (The main reason one would do this is to drag multiple tabs simultaneously to a new browser window, or from one window to another.) I'm giving Mac Safari a chance to win me over, but the very basic functionality of selecting multiple tabs appears to be completely absent. Am I missing something?

Having never needed or even thought to do this I see the behavior you are talking about. And I believe the Safari engineers may have been of a similar mind.

I see no combination of keys that will allow you to select multiple tabs, so I am thinking that may not be possible out of the box with Safari.

That does not mean that there is not an extension (Plug-in, in Firefox lingo) that might provide that functionality but I am unaware of any that do this. You may be out of luck.


Is Mac a computer or an operating system? I encountered this question when taking Apple's online survey:

My question is: What does the "A Mac user" mean here? Someone using OS X or someone using a MacBook?

Mac is the brand of computers (specifically, the hardware) made by Apple. The Macs on sale today are the MacBook, MacBook Pro, MacBook Air, iMac, Mac Pro, and Mac Mini.

Mac computers run on macOS (which was called OS X up until its rebranding in mid-2016). macOS, not Mac, is the equivalent of Windows, but since Apple wouldn't ask "Are you a macOS user" (the equivalent of "Windows user") and wouldn't ask "Are you a Windows computer user" (the equivalent of "Mac user"), they use the fairly reasonable grammar found in your screenshot.

You can also use an anology to sum it up: Mac is to PC, as macOS (previously OS X) is to Windows.

TL;DR: The first line of Wikipedia's entry on macOS pretty much sums it up:

  macOS is a series of graphical user interface–based operating systems developed by Apple Inc. for their Mac line of computer systems.


How to determine if a MacOS program on Apple Silicon is emulated x86 or native ARM from the command line? I have an M1 MacBook Pro and have downloaded both some native (ARM) and x86_64(Rosetta 2 emulated) binaries.

How do I determine from the command line which of these ISAs a particular binary file is?
Is there any way to know if a currently running program is running
native or under Rosetta 2?

Run file on a binary:
krismatth@KristophersMBP3 ~$ file /bin/bash
/bin/bash: Mach-O universal binary with 2 architectures: [x86_64:Mach-O 64-bit executable x86_64] [arm64e:Mach-O 64-bit executable arm64e]
/bin/bash (for architecture x86_64):    Mach-O 64-bit executable x86_64
/bin/bash (for architecture arm64e):    Mach-O 64-bit executable arm64e

Activity Monitor shows the architecture of running programs:


How to completely remove emails in OS X? So I added a Google account to Mac os X and then I decided to fetch my google mails by using "Mail" application..

But then I kept the Google account but removed the "Mail" application from the Google account settings and kept only Calendar and Contacts.

Anyway now when I search for lets say "cv" in spotlight it still finds things from my google mail.

How can I clean this?

If you don't have other Mail accounts with data that you want, quit Mail.app and delete the entire contents of ~/Library/Mail/

If you do have other accounts and only want to remove your Gmail account, quit Mail.app, open the V2 folder inside the above path and delete the folder relevant to the particular account that you want removed.


Can 'Find My Mac' work while the computer is sleeping? Is the 'Find My Mac' feature of iCloud supposed to work while the computer is sleeping? I use this feature to check on things every once in a while, as well as show the feature off to other people. Every time I show them though, it always lists the machine as being offline.

I ask too because a 'sleeping' mac does actually wake up every once in a while (in a very low level state), to basically check and update its mDNS/Bonjour config, as well as a few other minor things (I know specifically my iMac does this, I haven't looked on my MBA). I figured that if it was waking to at least check this stuff, it would also propagate to Find My Mac.

Final Update: So after switching around more network configs (and going just wifi), it actually worked worse - I couldn't wake the machine locally either (and this is with wake on network access checked). So I think its either something odd with my setup, or actual machine (I know already wifi is odd on it - I tried a defaults command to enable airdrop, and that didn't work either). My actual issue is due to the machine not being able to wake from sleep.

New Update: So, noticed a few things. Wifi was on, but not connected (nor should it be). I turned it off, and disabled the interface, and it still doesn't wake the computer up on the Ethernet adapter. I just now tested the opposite way, and it actually looked like it worked! Want to try again a bit later to make sure.

Update: I re-enabled Find My Mac, and verified that wake on LAN was active. While it did work earlier on, once the computer actually went to sleep (about an hour later), it never seemed to want to update, until I woke the machine. Is Find My Mac supposed to wake it anyways? Or would Find My Mac while sleeping never actually show its current location until the next wake? As a precaution, I restarted my Mac and Airport Extreme just recently. Also, could this be a port forwarding issue on my FiOS router?

If the Mac is sleeping there is no way for iCloud to locate it and it appears offline.

However, as you noted, you can enable Wake for network access in energy preferences for it to periodically wake and check the network allow remote wake up using and AirPort.

When the Mac connects to iCloud next time, your commands (locate, lock, wipe, message/alert) are sent to it.


Why does High Sierra remove my Login Items? After updating to macOS 10.13.1, my Login Items have vanished. Some users have reported this behavior in earlier betas, but this is the first time I've experienced it in a release.

Is there a reason for this behavior. Is there a way to identify what items I had configured  so I can restore them?

I have lost all my login items too after upgrade to macOS 10.13.1.

You could take a look the plist file at ~/Library/Preferences/com.apple.loginitems.plist, it may still contain names of login items, then add them back manually. I recovered mine in this way.

I guess 10.13 has moved login items config to somewhere else but failed to migrate old ones.


Maps has my address wrong when home Maps is not getting my address right. It has the street right but when home it says I'm not. I have tried everything.

Assuming iOS 8.1.3, in the Maps app, touch on the information icon in the lower-right corner, then touch the "Report a Problem" button on the next screen.


Mail won't open after installing the security update for 10.6.8 I have seen other people with this problem, but their Mail icon was moved out of the applications folder. My Mail is and has always been in the Applications folder, so the problem is not that. I reinstalled the original Mail from the original Snow Leopard installation disk and then installed the system combo update, but it still won't open. I am at the end of my rope!

After an OSX update (10.6.4, 10.6.6, 10.6.8 caused this issue to me) I had the same problem.  For the third time in 2 years.

If you're lucky this issue causes one hour wasted to reinstall from DVD, then re-apply patches hoping it will work the first time.

Now if you're tired of this, I have THE definitive solution for you: install thunderbird (which will import your messages even if mail won't open !).

Like with any other operating system it's best to keep operating system and productivity applications from separate providers to minimize risk of something like this happening.

After you move to thunderbird you can move your mail history anywhere, even on windows or linux.

Incidentally, this will also get you a more powerful mail client instead of mail which - besides the upgrade issues - is a really basic client.


How to change the order of the virtual desktops Is it possible to change the order of the desktop assigned to each monitor? It used to be setup so that they where all in sequence, 1 (laptop), 2, 3 however after working in a remote location for a while and plugging back in the monitors it switched to 1 (laptop), 3, 2 and now things are launching on the wrong screen. What can I do to get this fixed?

This occurs when the Mac fails to recognise the displays correctly. At reconnect, it 'forgets' what physical order you had them in.
One of the users on Ask Different made an app to keep a tighter hold on this - which I'm afraid I've been unable to track down. I hope they find this question & leave us a link to their app again.
In the meantime, a workaround would be to re-arrange your display order in System Pref > Displays > Arrangement.
You can drag individual displays into whichever order you would prefer.
If you click & hold any display it will highlight in red - on the control panel & also right round the display that is referenced, so you can easily tell which is which. The primary display is the one with the menu bar [which can also be moved, if needed]
Image showing 3 monitors, centre highlighted, primary assigned to left-most.

If your Mac is suffering from this 'forgetfulness' you may need to re-do this each time you change your connected monitors [hence the need for the app mentioned above.]
I'm assuming this is not actually the same as How to prevent Mac from changing the order of Desktops/Spaces which is actually a different issue with a simple fix in prefs.


Xserve display problems during installation I've had to reinstalled OS X Server on 2 Xserve machines. The first went fine. See this link for some background.

When I went to the second machine, everything seemed to go OK. As it takes 30 minutes or so for the installation to copy and install files, I got that far and went out to run a few errands while it finished. When I got back, the display had gone black.

I have a mini DisplayPort cable from the server to an iMac. Pressing Command ⌘+F2 switches between the iMac's display and the attached server.

This worked fine all the way through the reinstallation on the 1st server and fine with the second until I got back from my errands. I've also tested the iMac with the first server; it works fine, so no problem with the iMac or switching it to show the display of another machine.

Having just done the install, but not the setup, yikes! What do I do now? The machine hasn't shown up on the network yet, I may have not connected to the network yet.

Should I just shut it down and restart it?

Can I do a controlled shut down from the attached keyboard with some key sequence or combination (again with now view of what's going on)?

Seems like I have either:

a mini DisplayPort cable that suddenly went bad;
a mini DisplayPort on the Xserve that suddenly went bad;
or some kind a controller glitch or failure.

I can only get to the mini DisplayPort cable if I shut down the servers and roll out their cabinet (I have well ventilated but tight quarters).

Seems like I have to restart. Will I need to re-reinstall?

Any thoughts on the best way to do this appreciated.

The solution to this problem required reinstalling the operating system. It worked seamlessly the second time around.


Change output color of terminal (in Mac) to be different from typed text color I know how to change the color of ls output, but I would like to change the color of all terminal output.

To make clear what I mean, below is a picture of my terminal. My text color is orange.

However, I would want the -bash: p: command not found, test, and the output of df to be a different color, so that it is easier to see the difference between what I type. Is this possible?

This is how it looks with @jmhindle answer. You can change the number after setaf for a different color (e.g. 2 for green).

I think you can do this by installing a DEBUG trap in ~/.bash_profile.

See the answer to this superuser question.

I added the following:

preexec() {
    tput setaf 4
    :
}
preexec_invoke_exec() {
    [ -n "$COMP_LINE" ] && return
    local this_command=`HISTTIMEFORMATE= history 1 | sed -e "s/^[ ]*[0-9]*[ ]*//"`;
    preexec "$this_command"
}

trap 'preexec_invoke_exec' DEBUG

tput setaf 4 changes foreground colour to blue.


Any way to extract notes from iPod Touch backup? Is there any way for me to extract notes from an iPod Touch backup? I had forgotten to back up the notes on my old iPod Touch and subsequently lost all my notes on it. It's been a year and a half now, and the older computer with the backup has Snow Leopard clean-installed on it.

If I restore the older installation of Leopard with Time Machine, would it be possible for me to extract the notes from the iPod Touch backup? (1st gen, iPod Touch software 2.0)

Restore your old backup folder from Time Machine somewhere on your hard drive.  Then using iPhone Backup Extractor, extract the notes.   Your iPod isn't used in this process.

http://www.iphonebackupextractor.com/

This is probably the easiest way without resorting to wiping your iPod.


Downloading OS X Lion after the release of Mountain Lion I bought OS X Lion through the App Store long ago and installed it to my Mac Mini (Early 2011) which came with Snow Leopard bundled.

The Mac Mini was having some issues so I decided to format and reinstall using the Recovery Partition created by Lion. However, the process of downloading installation files was getting stuck and the installation did not advance, so I decided to install Snow Leopard instead and make the upgrade to OS X Lion from the App Store, like I did originally.

Sadly, I find that there's currently no way of downloading OS X Lion from Apple's site. What can I do? How can I get a hold of a product I paid for?

The Apple site prompts me to buy and install Mountain Lion which I don't want.

You can download apps you've purchased before (including OS X installers) from the Mac App Store application. Sign in and switch to the purchases tab:

All of your previous purchases should appear, including the Lion installer:

If you don't have the App Store, make sure you've updated to at least 10.6.6.


Connect and run commands over SSH using script I'm using a series of commands for deploying my files to production. This is currently done manually.

Is it possible to make these commands into an executable file? So that I don't have to copy paste these commands each and every time.

When the first line is executed i.e., connecting to the root server, it will ask for the password and I have to paste the password: xxxxxxxxxxxxxx

ssh root@server
pwd: xxxxxxxxxxxxxx
ssh-agent bash
ssh-add bi-master
cd /home/trans/bimaster
git status
git pull git@bitbucket.org:xxxxxxxxx/bimaster.git master

Note : I'm the admin of the server, Since the project is been done by different teams as of now, we have decided to do manual deployment (cannot use Jenkins or any other tools for automated deployment), as we have to check the status of some files.

You can use ‘expect’ to enter the SSH password when prompted. Changes to your script are bolded.

#!/usr/bin/expect -f
spawn ssh root@server
expect "*: "
send "xxxxxxxxxxxxxx
expect "$ "
send "… commands

spawn starts the command as normal, which in this case is SSH
expect waits until the matching text is shown on screen
send enters the text given, which can be a password or command to be run
expect waits for the shell to be shown (this should be changed to match against your shell $PS1)

Save this file, add the executable bit (chmod +x /path/to/file) and open to run the commands.

However, instead of this, you should be using SSH keys to connect to the server without entering a password, and the commands you wish to execute over SSH should be in a script on the server which can be run. Set up SSH keys, then you can run a remote script with ssh -t root@server "/path/to/script".


Can I prevent SMS from showing on the Lock Screen in iOS 4? I have some private SMS messages I want to hide. The problem is that they are displaying on main screen even when it's locked. So it was useless using password because it's displayed even with the lock.

How can I make SMS messages hidden on locked screen?

Go to Settings > Messages. There's an option "Show Preview" there. If you toggle this to off, it will stop showing SMS previews on the lock screen. This will also disable the alert popup when a new SMS arrives and the phone is not locked.


how can I delete a pkg file on a mac? I have a .pkg file for Malwarebytes on my computer. I can't send it to the trash nor delete it in any other manner. I would appreciate any suggestions.

I would try the following:

From the terminal type sudo rm -f <package name>. You should be able to remove it as root. Reboot in safe mode if necessary.
Download and install Cocktail. It has functionality for removing difficult to remove files.


MacBook Pro with Mountain Lion freezes frequently (full screen Flash in Chrome, Messages, HTC on USB) Problems following an upgrade to Mountain Lion on a 13-inch, Early 2011 MacBook Pro (MacBookPro8,1 with Intel HD Graphics 3000).

With Google Chrome, I was watching YouTube video fullscreen – Flash content. In the middle of video, I wanted to exit full-screen mode but neither the keyboard nor the trackpad worked. The video continued playing fine. At last, I forced the system to close and restarted.

Today I was just chatting in Messages and suddenly everything froze. I was able to move the cursor but nothing was happening.

Has anyone else faced this issue, or found a solution?

Update:
If I connect my mobile phone (HTC Wildfire S) to my MacBook Pro using USB, the Mac freezes every time while removing the USB connector.

Suspect an issue affecting the WindowServer process (long edition)

a more generic edition of this answer appears under How do you get system diagnostic files from OS X?

power users may prefer to read nearby Suspect an issue affecting the WindowServer process (brief edition …)

The symptoms you describe are familiar but not commonplace and in my case, not frequent.
Prepare for diagnosis
In Terminal, run the following command. Be prepared to enter your admin password for the operating system:
sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.stackshot.plist

Take a written note of the following key chord, you'll need it later:
Control-Option-Command-Shift-.
Diagnosis by the system
When the problem occurs:

use the key chord
for at least ten seconds, touch nothing
allow maybe five or ten minutes for all parts of the so-called sysdiagnose routine to complete – simply wait as long as you can (with this approach there'll be no on-screen indication of progress)
force a restart of the computer (Command-Control-Power).

After the computer starts:

in Finder, go to /private/var/tmp
seek a file or folder with a name beginning sysdiagnose_
if that file or folder exists, move it to a convenient place – your desktop, maybe.

Hint
Whilst I don't encourage carelessness, you can be a little careless with Control-Option-Command-Shift-. … if you struggle to avoid the fn key on your laptop, don't worry; including it by accident should not prevent the run of sysdiagnose.

Human analysis of diagnosis by the system
Hint: someone might like to ask a separate question about analysing the results of sysdiagnose – a more generalised answer could be useful.
If sysdiagnose_… from the /tmp area is a folder
Presence of a sysdiagnose_… folder (not a .tar.gz file) indicates that either:

the routine was interrupted before completion; or
some part of the routine could not complete.

If sysdiagnose_… from the /tmp area is a file
Presence of a sysdiagnose_….tar.gz file indicates that all parts of the sysdiagnose routine completed, and that the results were archived. If you wish, open the archive – its contents will appear as a folder.
Folder contents at a glance
In the first screenshot below – an example of a completed run of sysdiagnose - I have selected two of the items that may be of interest in a case such as this.

Note that it may be normal to find at least one empty file.

Amongst the .crash, .hang and .spin files – or in the top.txt file – might be a good sign of what was wrong shortly before, or during, the period when you lost control of the computer.
Related:

How does 'stuck' (in results of 'top') relate to 'not responding' (in Activity Monitor), 'spin' or 'hang'?

For an incomplete run of sysdiagnose it may be useful to focus some attention on files that are abnormally empty …

Technical
stackshot(1) OS X Manual Page
sysdiagnose(1) OS X Manual Page


How can I construct my grep command on zsh to return a specific value? I am trying to use the command line to extract a specific value from a web page.

The page is from the VS Code marketplace: https://marketplace.visualstudio.com/items?itemName=HCLTechnologies.hclappscancodesweep and I am after the number of installs.
I managed to get to a point where I can isolate up to this:

{"statisticName":"install","value":206.0},{"statisticName":"averagerating","value":5.0},{"statisticName":"ratingcount","value":8.0},{"statisticName":"trendingdaily","value":0.0},{"statisticName":"trendingmonthly","value":88.950276243093924},{"statisticName":"trendingweekly","value":28.7292817679558},{"statisticName":"weightedRating","value":4.668447071838485}],"installationTargets":[{"target":"Microsoft.VisualStudio.Code","targetVersion":""}],"deploymentType":0}

I am on a mac and using zsh. The command I'm currently using is:

curl -G "https://marketplace.visualstudio.com/items?itemName=HCLTechnologies.hclappscancodesweep" | grep -Eo {\"statisticName\":\"install\",\"value\":.+\}

The desired output of this command should be:
206.0 which is the number I'm after. If you can trim it down to 206 that's even better.

I have 2 main problems:
1) I can't isolate the match to start right before my number. I tried \K but that doesn't seem to work on the mac. I did not see an option to use groups either.

2) I can't make the matching after my number stop after the first match of a curly bracket }. Keep in mind the number can vary in length, so I want to stop it where the JSON stops.
I did actually try using [:digit:] and [0-9] to restrict to the number, but that did not work either and that's why I went down the curly bracket path.

I did see some options out there to work with the JSON part and extract things there, but the environment I'm working with does not have the flexibility of installing other utilities, so I need help to achieve this with a "vanilla" environment.

P.S. I'm working on Catalina 10.15.4

grep isn't well suited for data scrapping, you are better of with sed in such cases.

curl -sG 'https://marketplace.visualstudio.com/items?itemName=HCLTechnologies.hclappscancodesweep' \
    | sed -Ene 's/.*\"install\",\"value\":([0-9\.]+).*/\1/p'

The first part of the substition matches only once in the HTML file so there isn't even a need to select the correct line first.

To get the number without the decimal point use

curl -sG 'https://marketplace.visualstudio.com/items?itemName=HCLTechnologies.hclappscancodesweep' \
    | sed -Ene 's/.*\"install\",\"value\":([0-9]+).*/\1/p'


My MacBook Pro disconnects from the WiFi when not in use I usually download large files overnight but recently I had my mac formatted so all the settings were lost. I not that much of a techie person and I tried adjusting the settings and all but I don't really know what I'm supposed to do.

After I start my downloads, I plug my mac to its power adapter and dim the screen. To my surprise, the wifi gets disconnected when my mac is not in use thus stopping all my downloads. HOW DO I PREVENT MY MAC FROM DISCONNECTING FROM THE WIFI?

Here are my energy saver settings and I currently use Yosemite:

Try unchecking "put hard disks to sleep when possible"


Is it possible to disable or hide the digital zoom controls in the Camera app on iPhone? I don't think I have ever used the digital zoom feature in the Camera app. The controls are just in the way when you wan't to focus something in that part of the image. So, if possible, I want to hide them. I'm not afraid to jailbreak my phone if that is what i takes. Any answer appreciated.

I have an iPhone 3GS.

Currently there is no officially supported method of disabling the digital zoom feature. One way around it that I use when I (rarely) need to focus on the lower screen portion, is to focus on the subject, then move the camera's view to the preferred state. The camera will preserve this focus state long enough for a picture.


Drives and dmg's mounting okay but not appearing in the Finder sidebar Drives and dmg's are mounting okay on my Mac, and I can find them at /Volumes/. However, they aren't appearing in the sidebar in the Finder. What's the best way to start fixing this?

In Finder you can show or hide the disks and other devices

Go to the sidebar and mouse over DEVICES you get to the right text that says Show or Hide. Click on that word to toggle the display of the devices.


Finding CodeBlocks that works or fixing bugs? I am using Codeblocks to develop C++ code on OSX Mavericks. I am currently running into the problem where the software occasionally will crash and than continue to crash every time the software is started again. I know for this software package there is a bunch of different sources: code blocks pre built apt, mac port version, and I believe even a version you can download through svn or git hub which is the nightly build.

Additionally, I also have problems with the auto complete sometimes not working.

Can someone recommend a version that worked for them with a reasonable explanation on how to install it? Or, if you had similar issues with code blocks, how you went about fixing the bugs?

By the way I am using the pre built 32 bit apt from code blocks website.

I was having the same issue.

A workaround / fix is to  disable the autocomplete plugin if you consider "works" without autocomplete.


Migrating applications without using Migration Assistant? I am migrating from a Mac Mini (early 2009) running OS 10.6.8 to a Mac Mini (2012) running OS 10.8.5.  I made several attempts to use Migration Assistant to copy everything; all ended hung at "4 (or 3) minutes remaining" for hours and hours.  According to Google lots of people have this problem, but if anybody solved it I haven't found it.  2+ hours on the phone with a senior Apple support technician didn't solve it either.

Noting that it's always copying applications when this happens, I reran Migration Assistant copying everything except applications, and that completed.  (I have question marks in my doc where those applications should be.)  I tried Migration Assistant once more on just the applications, in case that made a difference, but it still hangs.

Clearly Migration Assistant doesn't like something in my set of applications, but I've found no diagnostics that would tell me what.  If it were choking on one (known) application, for example, I might try temporarily removing that to see if it helps.  I've got enough applications that I don't want to just start guessing.

How should I go about migrating my applications?  I think I need both the actual applications (contents of the Applications directory?) and settings (preferences, browser add-ons, etc).  Where do I find all the stuff I need to copy, and do I need to do anything more than copy the right files to the right places?  On Windows I know there'd be registry entries and config files and DLLs and stuff scattered across the disk, but Macs are different.  This is my first Mac migration.

I'm trying to avoid reinstalling (and then reconfiguring) all of my applications because (a) hassle! and (b) some came on CDs/DVDs and the new machine doesn't have a DVD reader.

I plan to update the OS on the new machine when I'm done, but I thought that migration might be easier if the OSs were closer to each other.

It really depends on the application. With the advent of the Mac App Store a lot of applications have become more self-contained (everything lives within the app bundle). But, you're talking about an older systems so again, it just depends on the application.

The easiest thing to try is just copying them over from the old /Applications folder. If that doesn't work then your best bet is to re-run the installer (assuming it's still compatible with 10.8). If your old Mac has a disc drive you might be able to use the Remote Disc feature to complete your installation.

I know some app developers have started to make digital copies available for people who find themselves without a DVD drive anymore- but you might have to reach out to them for help.


Force external display refresh rate I have a 27" screen which is connected to my mid-2012 MacBook Pro retina through a HDMI/DVI-D (HDMI on the MacBook Pro, DVI-D on the screen).

Before I was using a adapter DisplayPort+USB/DVI-D and I was able to get 60Hz refresh rate.

Now with the HDMI/DVI-D I have only 30Hz.

Is there any way to change (by forcing?) refresh rate to 60Hz?

Or is it a hardware limitation?

NOTE: I can't change the Refresh Rate value from System Prefs, the menu is disabled and the value is set to 30Hz.

EDIT: Here's the System Prefs window

cscreen

You can use the freely available Terminal app cscreen to force display settings. The app is pretty self explanatory.

brew cask install cscreen

cscreen -h
Usage: cscreen [-d <depth>] [-x <width>] [-y <height>] [-r <refresh>] [-s <display>] [-v] [-m] [-f] [-l] [-h]
           [-d <depth>]    : specifies the bit depth (bits per pixel)
           [-x <width>]    : specifies the width in pixels
           [-y <height>]   : specifies the height in pixels
           [-r <refresh>]  : specifies the refresh rate in Hz
           [-s <display>]  : specifies which display to use (defaults to main display)
           use a as the option to -s to specify the action on all displays
           [-i <displayID>]: picks a display based on CGDirectDisplayID (permanent per display)
           continue to use '-s a' for "all displays"
           [-v]            : display valid modes (use -s to specify display or nothing for the default)
           [-m]            : require an exact match
           [-f]            : forces settings (ignores safety mechanisms; USE AT YOUR OWN RISK)
           [-l]            : lists the current displays and modes
           [-p]            : sets the requested display to have the menu bar
           [-h]            : displays the usage

           Note: Using -p will change the display index so you will likely want to use -l again to show the current
           displays if you wish to use -p a second time.


How to manage multiple ssh sessions with ease on Mac OS X At my upcoming job i will handle many servers with SSH access. It will be like ~100-120 hosts, with different username on most of the hosts, and i'm pretty sure i will not remember each host domain name, not to mention which username is on each host.

Is there a tool for Mac OS X (Lion preferably) which would allow me to define a session for each host (in a session i mean username and some ssh options), show list of such sessions and connect on click/select automatically?

There are two ways I manage, or have seen people manage, SSH data:

Good 'ole, command line, plain text, ssh_config file.

Create a file called config inside ~/.ssh. You can specify global parameters by putting them above any host declarations. When I started using MacPorts, I had to explicitly define a default SSH Private Key to use automatically when connecting, so as the very first line of the file I put;

IdentityFile ~/.ssh/id_rsa

When you define custom rules for hosts (and you can even use * as a wildcard), it looks something like this:

Host prod-*
  User jason
  Port 2222
  LocalForward 5901 localhost:5901
  IdentityFile ~/.ssh/work-id_rsa

Then when I run ssh prod-script for example, all the rest of the rules get applied automatically.

A lot of people who don't want to manually manage all their stuff in such a cumbersome manner quickly find JellyfiSSH. (Mac App Store Link. The same people also became very annoyed when it stopped being downloadable for free.)

JellyfiSSH gives you GUI access to almost everything that can be specified in the command line or ssh_config file. JellyfiSSH is just a configuration storage app for organization purposes, because it generates the commands based off the options you set and upon clicking connect, opens a new terminal window with all of your options defined on the command line. JellyfiSSH is not a terminal app on it's own.


Password settings do not appear! At random times Apple Mail rejects the current stored passwords for my gmail accounts.  When I go into Preferences>Accounts>Server Settings, the windows that are supposed to appear to change or update the passwords for incoming and outgoing mail simply are not there!!!
How do I update or change the passwords, then, in Apple Mail so that I can have my emails appear properly, as they do when there is no password issue being created by the site itself?

I found this unanswered question at discussions.apple.com: The link for the apple.com post

The link for the tigertech post that gives detailed instructions in fixing password issues

A screen shot of the tigertech post that shows what the Preferences>Accounts>Server Settings window is supposed to display

Welcome to Apple.SE JONAllow. What you're seeing in the mail app is the expected behaviour of the mail app. Both of the screenshot are of two different conditions i.e. Gmail and Company account.

Gmail doesn't allow server settings to be changed via Mail.app Preferences pane. While, accounts such as of an institute of study or work have to be configured in server settings via said pane.

So to change passwords, I suggest going to Mac Preferences -> Internet Accounts,   select the said account, click "-" in the bottom. And add it back.

IMAP mailbox will not pose any problem restoring all mails. It might take time though.

One unverified alternative is that you see the sidebar in the mail and find a

error sign. Tap on it and see if it gives other options like "Try again" and hope for a password reset prompt. You might see "System Preferences want to use google.com". Allow it.

Hope it helps!


Mac Mail not including original email headers in Reply Is there any way to make Mail include the to/cc email addresses when forwarding/responding to a message? currently all I get is:

On Oct 15, 2013, at 2:47 PM, John Doe <jDoe@jDoe.com> wrote:

what I would like is:

From: Dakine83
Sent: Tuesday, October 15, 2013 2:55 PM
To: John Doe
Cc: Jane Doe
Subject: Re: Clean the fridge!

Not including who has seen the email chain is a serious omission, hopefully it's just a setting I can't find.

Unfortunately, you can't customize the Reply/Forward headers without the help of QuoteFix or ReplyWithHeader.
To customize the actual headers when viewing an email message, I'll quote this MacFixIt article:

To alter the headers that Mail includes, you can go to the Viewing section of the Mail preferences, choose the Custom setting, and then add or remove any fields of the e-mail header that you wish to see. Unfortunately you need to enter the field names manually, and many times e-mail services will append their own header details to a message, especially for handling spam or other security features. Therefore if you are not sure what the header titles are then you will need look them up in the raw source code for any particular message.
To do this, select a message in your inbox and then press Option-Command-U or choose "Raw Source" from the View > Message menu. In the resulting window you will see all the message details in plain text. Header fields will be the text before colon characters with dashes in them in place of spaces, and may include items like "Delivered-to:" or "Return-Path:", or custom items like "X-Virus-Scanned:" for antivirus information.
When entering these details in the custom headers list, be sure to enter them as is (including the dashes), after which be sure that Custom is selected in the preferences and that the Details link is clicked in your e-mail messages.


How to get Siri to read result from the web Siri is frustrating. I can ask her a question like "what causes brain freeze" (as one does), and she'll say "I found this on the web". But if I then ask her to "speak screen" or "read page", or even "read it to me", she has no idea what I'm talking about and tells me there's nothing to read.

Folk, I understand how to get my phone to read a page. What I don't understand is how completely hands-free you can ask Siri a question and get her to read the web page of the result she just found you.

Alexa can do it. Google can do it. What's wrong with Siri?

AFAIK, you can use Siri to speak screen when the results are open in Safari, or when it shows specific excerpt from Wikipedia or WolframAlpha etc. for say, word meanings or definitions.

For the results in the overlay, it seems not possible to me.

I search using iPhone's spotlight and then use "search the web" at the bottom in case I need more results.

You can look into setting up a automation for opening safari and reading it out aloud.


Mail.app import from Entourage failed I am trying to import my entire folder structure from Entourage 2008 to Mail on a Mac running OS X 10.5.8.

First I tried to export the whole email database from Entourage to the Desktop as a .rge file. The export aborted with a message saying that my Entourage database is corrupt and that I should rebuild it.

I then went over to Mac Mail and imported the Entourage folder structure through File > Import mailboxes… > Entourage. The bulky import did take some time and the progress bar never reached its full length, but at the end the import said it was successful.

When I checked the imported folder structure in Mail I noticed that quite a few subfolders were missing. I checked Console and saw following message:

Mail[2899] Applescript Error:
  aliasForMailImporter got an error:
  AppleEvent handler failed.

What does that mean and what can I do to move my subfolder structure over completely?

Based on the message saying that your Entourage database is corrupt and needs to be rebuilt, I have to guess that your Entourage database is corrupt and recommend that you rebuild it.

As the saying goes, "Garbage in, garbage out."

Here are the directions on how to rebuild your Entourage database.


WWDC scholarship app requirements? I am trying to apply for the WWDC 2015 scholarship. I have an app that record trails (like Runkeeper) that I'd like to submit for the scholarship (and submit it to the App Store). However, in the scholarship app requirements, it states that the app must tell something about the developer, and the app must have the developer's name as its name. However, the app that I'm trying to submit neither tells about me, nor does it have my name as its name. Does the scholarship accept these kind of apps? I could extend my app to include info about me. But does Apple allow submitting an app to the app store and modifying it so it abides the scholarship requirements? I'm sorry if my question sound stupid :)

The app needs to be an interactive CV/Resume that shows off your creative and technical ability, but also talks about your background and projects you've worked on. Submitting an app you've already made that serves another purpose isn't what they're looking for, though you can (and should) submit links to other pieces of software you've made in addition.

More detail is given in the scholarship requirements section 1: https://developer.apple.com/wwdc/scholarships/Scholarship-Guidelines-and-Terms.pdf

Good luck!


Where are my old (previous) iCloud files after upgrading to OS X 10.10 Yosemite? I previously had about 200 .txt files saved in iCloud via TextEdit.

After installing the Yosemite (10.10), there is now a folder hierarchy in iCloud, and all my previous files seem to have disappeared.

I have looked in /Library/Mobile Documents -- they're not there.

I have tried showing hidden files and looking through the Library with no success.

update - I have several Time Machine backups made well before I updated to Yosemite, but there are no documents in /Users/(username)/Library/Mobile Documents/(textedit folder)

The files are still there, just no longer accessible via Finder.

You can use ls ~/Library/Mobile\ Documents/ to verify. To note, the folder has always been treated specially, and instead of just the App names, you'll see some unique strings followed by the app name.

For a paid solution, Path Finder by Cocoatech still displays all the files, helpfully removing the extra strings as Finder used to, while also directly jumping to the Documents section. It works pretty well, but Path Finder is expensive for its relatively unimpressive set of features, and the developers try to milk it each year.

For a free solution, Plain Cloud works, although its UI is pretty rough and bare bones, and the app itself is quasi-abandoned. (Currently there is a rendering error that causes the first app to be partially obscured, but using the reload button fixes this.)

Hope this helps.

PS. More directly to your question, if the files were truly stored in TextEdit's iCloud you should be able to access the files under TextEdit > Open > under iCloud Library choose TextEdit - iCloud.


How can I download macOS Catalina on a 2011 Mac mini that doesn't support it? Note:  I only want to download it, not install it on the 2011!
The App store doesn't let me download it, but I don't want to install it, I just want to download it and create an USB installer so I can restore my other Mac.
How can I do this?

You can use Dosdude1's Catalina patcher to download the official Catalina installer from Apple's servers.
Disclaimer: I'm not a fan of bodging macOS to work on unsupported platforms, especially for "production" machines.  However, if you're looking to tinker and this is something to experiment with to learn, I say have at it.  If you need the latest OS for work, get a machine that supports it.
Basically, what you're going to do is trick macOS and ultimately Apple's servers into believing that your machine is capable of running Catalina so it will download.
When you run the Patcher, make sure you uncheck "Auto-apply Post Install Patches" found in the Options menu."  This is because you're not installing Catalina onto this Mac; all you want to do is get the installer so you can create the USB Installer.
Once you will get to a screen where you can either browse for an installer or download a copy, select the download option.

Download the DMG, it will be approximately 7GB. From there, you can make your offline installer.  The Terminal command is as follows:
sudo /Applications/Install\ macOS\ Catalina.app/Contents/Resources/createinstallmedia --volume /Volumes/Catalina --nointeraction

If this worked out for you, I encourage you to buy him a coffee or a beer (or maybe even dinner) by sending a donation his way (I'm not affiliated, I just appreciate people's hard work).  You'll find the "donate" link on the software download page.


Weird encoding in executable files in ios apps I'm trying to see how does certain ios apps executable files look like, what I do is export the app files to my computer using iexplorer, I then took a look at the info.plist to see the executable files, after that I opened them with my notepad to use the UTF-8 Encoding, but here how does things look like in both files-in the opening of both of the files I see english words that are expressing directories:

Sample of file 1:

‹"Ò.(?!ÑNÓU£C°îXjøe”Ú5O•½°{^ÿÝŒEÌrôðæ$@[3,ÔÜ£æ»8I˜hGw!*aHÒQ•tœl²þ„™AÍçßÍæ†´³)è:cÌ7H5æß-eFç¯î&Ø\n,$Ë$y»¥ÁB^6ÙP; i(q,AÅ
âðð·'©=Ÿa"v!PBÛÚ"¤¬‹Wj·;ËsÌŽÚâZüŠ–ÇüÉ;ÜA´sI«¸Üæ¿÷ ›‚‰.êøLž

Sample of file 2:

ßêª§gö«húDªÝn¡±CÅÁ¹ â=Ø‰ˆ4|®b¡  JeW-É¯ðó<n!¿mªJŒS£šŠ¿)ÙP"ã¢œÛôRW³tÖÙiŠ/7’¬(.æIó£™\NÒèË0¾jDçéM«Q/rªa`NÌhó¾ByUkézAµI—Ê6èøÁœ.gÄkß±ŠÊbN¬9ó9XˆU_ô°Š Y—9cÍq²Xi“¢•¢^+3Ø¨ñTÒ¦”¦Ø+PEOÖ–lci5^?÷¤(131dv°t]†™6>¦xgýgeéÀXœH7ßJÉ" 3‡rÜ6ÒI_   ƒr cdÅá¸|íð¼l;Töl±”›MÛ˜±o/ôÇô#¬RS;Y¥!ÜzGò“vî©6ØR¡‚>Ì0m5
ŸzrPÐiDMÊ|Þ·9âëYß,pØƒ‹£x—.àN5îüÝrjœG]Æ·

Ironically in the second file I can see a huge block of english words absolutely fine, but I dont get it why I don't see the whole file very good? I have also tried to open the files in an objective-c compiler after I have made them .m but that again was useless?

iOS applications consist of compiled code and additional support files, you would need decompilation tools of some kind to get back from the compiled code to readable source. As a starter see

IPA File Format
.ipa (file extension)
Bundle Programming Guide/Bundle Structures

If you just want to understand how iOS apps are developed you might be better of by looking at sample code within Apple's Developer Documentation and/or some of the various online repositories/courses.


How do I shut off a USB fan automatically when the Mac goes to sleep? I have a Mac Mini 1.1 on which I updated the EFI firmware to v2.1 and installed Mac OS X 10.7

I'm wondering how I can cool the Mac with an external fan somehow.
I found the internal cooling to be slow, so I put an external handmade USB fan on the system in an open case and this works well for my purpose.

The problem with the external fan is that when I put the computer to sleep, the fan keeps on working and I don't know how to make it stop.

I don't want to use the system fan as it looks very weak and makes a lot of noise at 3000 rpm. I don't like noise.

To expand on the accepted answer, on some desktops, hibernatemode 1 is not available, see the manual page for what's available, go to terminal:

$ man pmset

(q to exit the man page, or esc, then q key)

Scroll way down to "SAFE SLEEP ARGUMENTS", it'll list which hibernatemode is available on your system, my old iMac says 0, 3, 25

I set it mine to 25 (write RAM contents to disk, then full power down). Originally devices like USB hubs won't power off when the system is in sleep mode, now it does.

However doing this will make sleeping and waking much slower. I'm still trying to see if I like this, now I close almost all open apps before putting system to sleep to minimize disk activity. Not totally sure if I like this, might be easier to unplug that USB hub.


Why does someone else's notifications come up on my Twitter account for iPhone? I let my friend sign into Twitter on my iPhone and we deleted her account afterwards. After that, all her notifications, such as mentions and messages still come up on my iPhone. It’s really annoying. How can I get it to stop doing that?

In a nutshell - your phone asked to be notified and never cleaned up that request (or the clean up request didn't get processed correctly.)

If you simply uninstall the application and wait (perhaps using a different iOS twitter app in the meantime), the system will remove your device from that notification queue once it misses enough deliveries of a notification. This takes a variable amount of time, so you might want to force the issue by logging back in as your friend and removing the request to send notifications to your iPhone.

According to this thread on the Apple support forums, here’s that fix:

Log in with the previous account in Twitter settings.
Go to the Twitter apps’s “accounts” page.
Click “Settings” (bottom left).
Edit the notifications of the previous account by switching to “off” for “mentions and replies” and “message”.
Finally, delete the account again.


mba 2012 protect data against theft I'm looking for a way to protect my data files on my macbook air 2012

I'm a sales rep with sensitive client data. Always moving with my laptop in sleep mode.

So far I have my password set up, firewall enabled with all incoming connections blocked.

What else can I do to ensure data safety if someone gets an access to my mba SSD?

FileVault 2 is not secure (cracked in 40 minutes by security professions)
TrueCrypt looks promising but I'm concerned about battery life.

Any advice?

I found an article at TUAW which talks about the Passware Kit Forensic 11.4 software designed to 'crack' Filevault 2. However, this software can be foiled by two simple configuration points: 1/ turn off automatic login & 2/ shutdown the Mac instead of sleeping when you travel. In addition, the software requires physical access through a firewire or thunderbolt port so your computer cannot be touched through remote access.

The Privacycast site has this detailed article for your edification.

Seeing that you have a MacBook Air, with its astoundingly brief startup time, I'm not sure why you keep it in sleep mode whilst traveling. I never put my MBA to sleep unless I'm at home. If somebody steals my MBA while I'm home, I have a substantially larger problem on my hands.


Triple boot (Lion, Win7, Ubuntu) I currently have my MacBook Pro set up to dual boot OS X Lion and Windows 7. I am in the middle of a development project where I need to write some custom software that depends on proprietary drivers that only work in Linux. I have been using a vm but it's getting tedious. It would be nice to be able to boot up into Ubuntu natively.

Currently I have one 500 GB drive that has a 130 GB Windows 7 partition (bootcamp), Lion recovery partition, and my OS X Lion partition with the remaining space. When I try to partition the space i get "Partition failed, couldn't modify partition map because file system verification failed".

I am doing this through Disk Utility running from a Lion recovery flash drive. First aid shows no errors on the drive, but I repaired it anyway and still I get the same error when I try to repartition.

As a last effort I thought it might have to do with fragmentation of the free space so I defragged the drive (against my better judgment) using iDefrag, repeated the above process from USB recovery disk and still I get the same error.

What is the most efficient way to get 4 partitions: OS X, Lion recovery, Windows 7, Ubuntu Linux (booting using refit) without having to wipe everything and reload (reloading OS X and Windows 7 would be unpleasant)?

You should be able to use iPartition to solve this problem. I've had a lot of success with re-partitioning drives that failed when trying to use Disk Utility. It also depends on the partition scheme on the drive. If the scheme doesn't support repartitioning you will have to wipe the drive and start fresh.

I would suggest a GUID partition scheme.