How to stop Windows firewall from blocking Bonjour hostname resolution

Create a new Inbound Rule that allows traffic over UDP port 5353 in the needed security zones.

Step-by-step:

Open Windows Firewall Advanced Settings

Create a new rule in Inbound Rules

Under Protocols and Rules, choose Protocol Type > UDP and Specific Ports > 5353

Choose the appropriate security zones for your network. For more information on security zones, read the Microsoft documentation: How Windows Firewall with Advanced Security Works


One certain person can't hear me when I call.

First, just try again, make sure it wasn't just a glitch.

Then, to fully test...

Reboot all 3 phones, yours, boyfriend's, mom's.

Ring each person to test - that's 6 phone calls - you to mom, mom to you, you to boyfriend, boyfriend to you, mom to boyfriend, boyfriend to mom.
That last couple might feel odd, depending on how well they know each other, but it's the only solid test to see if it is specifically just an issue between you & your boyfriend.

If only one/two of those tests fails [the expected ones], the next test would involve each person travelling far enough that they are certain to be using a different phone mast & repeat the process.


What you're asking for is simply:

curl http://example.com/commandPage.txt

This will get you the contents of that URL.

If you need to see the headers as well, you can add -v.

Otherwise, you can even use telnet to do so. Just use:

telnet example.com 80

And paste the full request as quoted above, followed by one empty line.


Color profile for projector messed up after Lion upgrade

Yes, I'm having exactly the same problem. Check System Preferences > Displays > Color, and see if you have more than one identically-named profile. A possible workaround for this problem is to select another profile and then the original one.


Make Cmd+C do both Copy and Stop in the terminal

The temporary workaround to this

It is possible to remap keys on any program in System Preferences > Keyboard > Shortcuts > App Shortcuts. Click the plus icon, and select terminal in the application drop down. Then type the name of the function (Copy in this case), and then highlight the shortcut box, and press a desired combination. The window should look something like so:

The above is just an example. This can be applied to virtually any situation and application


How do I backup and restore my IPA app backups in iTunes 12.7?

This looks reasonably promising - but I don't know how it will work for future releases...

  Manually add items from your computer

  If you have media on your computer that you can't redownload from the
  App Store or iTunes Store directly on your iOS device, such as
  custom ringtones or iOS apps, you can drag and drop the media from
  your computer to your iOS device using iTunes.

  Connect your device to your computer.
  Open iTunes. Make sure that you have the latest version.
  On your computer, find the item you want to add to your device. If you're looking for Apps, Tones, or Books (for Windows) that previously
  appeared in your iTunes library, you can find them in your iTunes
  media folder.
  Drag the item from your computer to your iOS device in the left sidebar of iTunes.


For me, iMovies' user interface is largely inscrutable. Perhaps that's because it caters to a video editor's workflow - something that's largely foreign to me. Anyway, this won't be a detailed answer, but hopefully enough to inch you forward.

The main thing I've noticed with markers is that they are like magnets: when the pointer is close by, it seems to "snap" to the marker. The only real use I've ever found for them is that they can be inserted during video playback (M). This is useful if you're looking for a place to cut a video, or make a splice to insert something. Here's another take on it.
Try using the "Precision Editor" (in the iMovie menu bar: Window->Show Precision Editor while a clip is selected in the editing panel. It may also help to "zoom in" (make the clip longer) using the slider in the upper right-hand corner of the editing area). Cf
Yes. The way I use this is as follows:

Split the clip (iMovie->Modify->Split Clip) at your chosen point.
drag one of the Transitions from the palette to the edit area in between the segments of the split clip
adjust the length/time of the transition with a double-click on the transition in the edit area

The picture shows the sequence, but you may have to view it full size to see the details.

Again - I'm no expert; you'll learn more, and quicker, by searching for help on the Internet. And keep looking! Some of the most useful features in iMovie are well-hidden: I think the "Ken Burns Effect" may be the best of these hidden features.


Time Machine - Preparing takes forever... (> 6hours)

How long since the previous backup?

There is a correlation between how much time/how many changes/the size of the changed files and how long it takes to prepare and how long it takes to complete.


Startup Disk full - Read-only- cannot boot Mac Mini

The error your getting when typing in the command means that the command you typed in has invalid arguments. That means that you didn't type the command correctly.

The reason it's not letting you modify the hard drive is because the drive is only mounted in read only mode.

Mount hard drive for read and write in single user mode

/sbin/fsck -fy

Then run:

/sbin/mount -uw

If it says something like invalid command try the commands without "/sbin/" at the beginning.

After your able to mount the disk erasing the files the other website recommended.

Also you mentioned you couldn't boot into recovery mode, but have you tried to boot into Internet Recovery Mode?

How to boot into Internet Recovery Mode

Hold Option-Command-R or Shift-Option-Command-R on startup until you see a spinning globe
Connect the device to Internet if prompted to do so.

Hope this helps and good luck on recovery your data


The pencil should last several years if you're careful with it. The two ways it will fail are physical damage and eventual consumption of the batteries. One way you won’t get long life out of a pencil is if you don’t use it and keep it charged monthly.

Avoid hard drops to the hard floor.
Avoid never charging it or letting the battery go totally flat

Things you can fix are overuse, the tips wear out in a year or so of moderate to heavy use. Apple sells replacement tips for your pencil at 4 tips for $19.  Apple also offers battery service for $30.
This link will describe how to tell if tip is worn. You may want to check it out.


Is there a way to prevent applications to run, like I can with selfControl to disable opening websites?

Freedom allows you to block apps on desktop, it includes a locked mode that should work if you block the right things, it is a paid app however.


How to download OS X El Capitan from the App Store even if never downloaded before macOS Sierra was released or purchased is grayed out

Whether or not you've downloaded it in the past, you can now download OS X El Capitan 10.11.6 (6.21 GB) via this link which will open first in the Browser, then in the App Store.

  OS X El Capitan

  This version of OS X El Capitan is for users running OS X Snow Leopard
  who would like to upgrade to macOS Sierra. If you are running Snow
  Leopard and would like to upgrade to Sierra, you need to install El
  Capitan first. This version of El Capitan can also be installed on Mac
  computers that are not comparable with Sierra.

Note: If doing this to downgrade from macOS Sierra.

In order to use the Install OS X El Capitan.app from macOS Sierra you need to create a USB Installer and boot the Mac with it.  You'll also need to erase the Macintosh HD and perform a clean install.  Make sure you have proper User Data Backups from which to restore your Data before erasing the Macintosh HD.

Have a look at Create a bootable installer for OS X. Excerpt show below:

  Use the 'createinstallmedia' command in Terminal

  Download the OS X installer from the Mac App Store. Quit the installer if it opens automatically after downloading. The installer
  will be in your Applications folder.
  Mount your USB flash drive or other volume. You could also use a secondary internal partition.
  Open the Terminal app, which is in the Utilities folder of your Applications folder.
  Use the createinstallmedia command in Terminal to create the bootable installer. Examples of this command are in the next section.
  For detailed usage instructions, make sure that the appropriate
  Install OS X app is in your Applications folder, then enter one of the
  following paths in Terminal:

  Path for El Capitan:

/Applications/Install\ OS\ X\ El\ Capitan.app/Contents/Resources/createinstallmedia

  Examples

  This is the basic syntax of the command. Replace volumepath with
  the path to your USB flash drive or other volume, and replace
  installerpath with the path to the Install OS X app.

createinstallmedia --volume volumepath --applicationpath installerpath

  The following examples assume that the OS X installer is in your
  Applications folder and the name of your USB flash drive or other
  volume is MyVolume:

  Example for El Capitan:

sudo /Applications/Install\ OS\ X\ El\ Capitan.app/Contents/Resources/createinstallmedia --volume /Volumes/MyVolume --applicationpath /Applications/Install\ OS\ X\ El\ Capitan.app


Found this a BH in a 20 second google search!
http://www.bhphotovideo.com/bnh/controller/home?O=&sku=902893&gclid=CJ6GgZrLkcMCFWFp7AodCg4AzQ&Q=&is=REG&A=details


Windows bootcamp file path on 2008 Intel iMac

The problem here is you are not specific about what you mean by "My imac hdd is starting to go." Being specific and detailed will always get you a better answer.

That said I can (hopefully) infer that there is some sort of error that has messed up a computer's ability to actually read the drive. This could be something as simple as directory corruption (reparable with something like Diskwarrior, Drive Genius or Tech Tool pro) to an actual physical error with the drive mechanism or circuitry.

The fact that neither a PC nor a mac can read the drive indicates (at least) the former. And trying a commercial disk repair tool would be my first suggestion.

Also Boot Camp actually partitions the hard drive and segregates all Windows files on a partition completely separate from the Mac O/S files. So when you boot into single user mode you are booting into the Mac O/S and browsing the Mac O/S partition.

There may be a way to mount the Windows partition in single user mode, but I just don't know how.

When you connected your iMac as an external HD (target disk mode) did your PC even see the Mac's drive? You would know by right clicking on the computer icon and selecting MANAGE. then go to disk management and look for the Windows Partition on the Mac drive that you just connected. I have never tried this and am not even sure if it will work.


I need to hide `Show all bookmarks` button in Safari 6

Safari lets you hide the entire bookmark bar, but not customize that one item.

The other items that show up to the left of all your bookmarks are in a fixed order and you can turn them all off except for the show all bookmarks icon.

Unless someone finds a hidden preference to write by hand into the safari defaults preferences, you may have to request this as a bug or enhancement request to Apple for Safari.

At best, you're stuck with the space that the back arrow takes on the left of the bookmark bar if you turn off all the other default items.


Does the smart cover keyboard on the iPad Pro have any features that a bluetooth keyboard wouldn't?

Well the keyboard does act as a stand, you get a folding triangle bit at the back and it holds the iPad at 45 degrees, so you can stick it on your desk and type away. The bit in contact with the desk is like felt, so the whole thing doesn't slide around. There is also a magnetic grip/strip that keeps the keyboard secure when its in the stand, so again it doesn't slide around. It all feels very secure and connected.

The keyboard also opens out completely and folds over the iPad and acts as cover for when you're carrying it around, so the screen is protected from scratches and other knocks. In this mode the keyboard has a small magnetic contact that switches the iPad off when you close the cover and wakes the iPad up when you open it back up.

Also the keyboard draws power only when you hit the keys, so doesn't put a drain on the battery quite like running bluetooth does.

Its also smart enough (because of the connector) to understand that pressing CMD + TAB together means switch between apps like you get on a desktop

So the keyboard really acts as a keyboard, stand, anti-slip device, scratch protection, screen cover, better battery, CMD+TAB  and 'go to sleep/wake' combination device.


Why is the coreaudiod daemon using 5% or more CPU?

The high CPU usage of coreaudiod is due to the ambient noise reduction software working (surprisingly, even when the built-in microphone is not in use).

Go to System Preferences > Sound > Input and uncheck the Use ambient noise reduction box.

Then, either reboot or run this one-liner to reload coreaudiod, and you should see coreaudiod CPU usage drop to 1% or less.


I'd recommend WineBottler; I have about 30 apps and games that work great with Wine. A few pointers though:

Check the Wine Application Database for various apps. This shows what version of Wine, what winetricks you need and what workarounds may be required.

Disclaimer: I'm a super maintainer
Check the official system requirements for the program/game. For older games, this will state which version of .NET or other framework is required—make sure you select the same version in WineBottler to be installed in the new prefix.
For programs that don't work, you can create a blank prefix with various frameworks installed and try combinations of winetricks without needing a new prefix each time.


I would think a good way of doing this might be to package your ~/Library/Mail folder within an encrypted disk image.  As long as it was allowed to grow to an acceptable size, I think it would work.  You would need to move the Mail folder into the disk image, then create a link from your ~/Library folder, called Mail, to the "real" mail folder on the disk.

In order to get to your mail, (I imagine), firing up Mail.app would follow the link to the disk image, which would prompt for your password, as it needs to mount.

Once you're done with your mail, you would be able to dismount the disk image and voila.

Never having tried this, I have no idea if it would work.


How to get old contacts back from Exchange on iPhone?

You can use this app to import your contacts from CSV file to your iPhone:
https://itunes.apple.com/us/app/contacts-in-import-csv-contacts/id549639443?mt=8

You can send CSV file to app via email attachment or iTunes. More details:
http://csvcontacts.wordpress.com/user-instructions/

You can handle phone number types correctly ("mobile","work","home"), import birdthays from any date format and many more.


Cloud storage options for iPhoto's primary storage (not for backups)

Your best bet is to wait for the release of Photos for OS X Yosemite, which is going to replace iPhoto early next year and will do exactly what you're asking for.

You'll be able to store all of your photos in iCloud, and the Photos app will dynamically cache only the most recent and/or frequently accessed photos locally, freeing up lots of disk space.

Pricing will be 99¢/month for 20 GB or $3.99/month for 200 GB (or 5 GB for free, but that's really not much). There's also going to be a 1 TB option, but Apple hasn't announced pricing yet.

OS X Yosemite and the new Photos app will both be free updates, and will run on any MacBook Air released in late 2008 or later (which is every model other than the very first one).


Discrepancy in hard drive space; can I delete these files?

You can certainly delete the two temporary items in your list:

/System/Library/Caches/com.apple.coresymbolicationd/data/
/private/var/folders/zz/CFNetworkDownload_L4uNTH.tmp

Avoid deleting the folder structures but large files in these locations can be safely removed.

To be extra safe, restart your Mac first and then remove any files. The restart will ensure the files are not in use.


My Brother printer not working in macOS Big Sur(11.3.1)

Brother recommends using AirPrint with Big Sur. Unfortunately, your model does not support AirPrint. As an alternative, Brother recommends you download Brother iPrint&Scan from the Apple App Store. Note: Most reviews for the Brother iPrint&Scan software are not very good.
When viewing the Downloads webpage, there is no printer driver available for macOS 11. Therefore I would assume Brother will not be releasing a printer driver for your current macOS 11.3.1.


Find, compare, delete duplicate music files with Terminal

Use iTunes as per Apple's note

  Choose View > Show Duplicate Items to show duplicate items (matches are based on the song name and artist).

  Duplicate items will be sorted next to one another. Review each item to determine which one you'd like to remove from your library. You can compare the track length, date added, genre, play count, size, bit rate, and more to help you determine which item you'd like to keep and which item you'd like to remove.

Then choose the item to delete and hit the delete key

There are apps that automate more of this e.g. Dupin


How can I try to boot a completely stuck Macbook Pro?

It could be something as simple as the MagSafe DC board or it could be the whole logic board. See below:

Normally, I wouldn't recommend that a user change out this part as Apple goes out of their way to make a complex assembly, but since you have an oscilloscope on your workbench....

The part is relatively inexpensive as compared to a logic board and I have fixed MacBooks where this component has failed.  Ifixit has excellent tear down instructions on how to get at this component.

You didn't specify which specific model, so I grabbed the 2013 model for reference.  The link is:  https://www.ifixit.com/Guide/MacBook+Pro+15-Inch+Retina+Display+Early+2013+MagSafe+DC-In+Board+Replacement/17055.

If it isn't the right model, you can find the correct one on their site.  I hope this helps...


Apple lists all software versions that run on models here:

Mac OS X versions (builds) for computers - http://support.apple.com/kb/HT1159

So you could focus on models that shipped with Snow Leopard and perhaps look at even older models that meet the minimum system requirements for Snow Leopard.

Mac OS X v10.6 Snow Leopard - Technical Specifications  - http://support.apple.com/kb/SP575


When attempting to open some MS Word Docs I'm asked to download - STHeiti and other fonts

The solution was hinted at in the comments.

Open FontBook: Launch Font Book.app (located in the Applications folder).
Find the fonts in question: Select "All fonts" in the sidebar and search for them using the search box in the upper-right corner of the window. Once found, each will be greyed out.
Download the font:Either press the "Download" button in upper-right corner of the preview pane or right-click the font to display the context menu and select "Download".
Smile now that MS Office doesn't ask you skip/download whenever you open that doc again.


Will AirDrop work between an OS X virtual machine and an iPhone?

Is your question here really "How do I get files from a Windows computer onto an iPhone", and you're using an OSX VM to enable AirDrop to achieve that?

If so, you can look at several other ways of sharing files:

DropBox
iCloud for Windows

And most of the big file-sharing services have iPhone apps that will allow you to upload from the desktop side (OSX, Windows, Linux, etc), and access them on the phone.


How can I sync sent mail from another device on my iPad?

The other device that is sending email probably isn't saving them to the Sent folder.

If you're using the Yahoo! website to send mail, you can go to Mail Options > General > Sending Messages to fix this. See the their support article for screenshots and more info: http://help.yahoo.com/l/us/yahoo/smallbusiness/bizmail/options/options-17.html

If the other device is using OS X Mail, go to Mail > Preferences > Accounts > Mailbox Behaviors and make sure "Store Sent messages on server" is checked.

For Mail on iOS, Settings > General > Mail, Contacts, Calendars > (your account) > Account > Advanced and make sure your sent mailbox is on the server.


How can I restore all files i deleted in the Applications floder?

Without being at the helm of your computer, I would advise a fresh installation. Reboot into recovery mode and reinstall OS X. This should restore all system files, and your personal files should not be effected.

You can boot into recovery mode a number of ways. One would be to hold alt at boot, then select your Recovery HD. In some instances, an OS X user may not have this drive. Instead, you may want to try Command+Option+R for Internet recovery.

A program like PhotoRec, which comes bundled with TestDisk. http://www.cgsecurity.org/wiki/TestDisk_Download

It runs in Terminal, but you would be able to select your drive and recover all files. Note that any files that have been overwritten since they were deleted (which is very likely) will not be recoverable.


Multi-Boot Windows 10 & Various Linux Distro on External SSD

A short answer to your question will not fix your problem, but at least you may become more aware of the difficulties installing other operating systems on Macs.

Both Windows and Elementary install their boot files in the hidden EFI partition. When holding down the option key at startup, you invoke the Mac (firmware) Startup Manager. This startup manager does not detect all possible correctly installed operating systems.

  The Mac Startup Manager assumes each EFI partition will only contain at most the boot files for a single operation system.

While both Windows and Elementary are using the same EFI partition, you will not be able to use the Mac Startup Manager to boot both operating systems.

Possible solutions are:

Use more than one EFI partition. A drive can have more than one EFI partition. Additional EFI partitions do not have to reside at the beginning of the drive.
Use a different startup manager. A free startup manager would be rEFInd. I prefer to install rEFInd so this manager can be booted from the Mac Startup Manager, the rEFInd will then allow you to select other operating systems. Actually, rEFInd instructs the Mac firmware to boot the selected operating system.

BTW, I have found difficulty installing most versions of Linux to use an EFI partition other than the default. I usually have to manually move the Linux boot files to an alternate EFI partition. Also, care must be taken to insure any Windows boot files are not overwritten by a Linux installer. The file that usually is overwritten is EFI/Boot/bootx64.efi. This file is copy of the EFI/Microsoft/Boot/bootmgfw.efi file.

You can access any EFI partition from macOS. To access the primary EFI partition on the first internal drive from the Finder, enter the command give below in a Terminal application window.

sudo diskutil mount disk0s1

To unmount, enter the command given below.

diskutil unmount disk0s1

In your case, make the appropriate substitution for your external drive.

Below are the elementary boot files store in the EFI partition. This image was captured from an VirtualBox install. Note: the files EFI/BOOT/bootx64.efi and EFI/ubuntu/shimx64.efi are identical.


The Google Chrome browser can render AsciiDoc files.  Just open an AsciiDoc file from Google Chrome using the menu item File -> Open File or the keyboard shortcut Cmd-O, and you should see the "live" file.

(Edit: I forgot that this requires the Asciidoctor.js Live Preview extension for Chrome).

In your editor, when you make changes and save the file, Chrome will automatically update its view.

Also, some editors (e.g. Atom - see https://atom.io) also have plugins that do live previews.


What is the difference between this disks (0 and 1) on my Mac?

The primary difference is that disk0 is your physical disk and it contains three things: GPT header table, EFI partition (that does not share space with the other partition disk0s2), APFS Container (that does not share space with the other partition disk0s1).

disk1 is how the APFS container is shared out to store other files that all share free space.

The details of APFS are on WWDC 2016 where this was introduced. The image above is from this developer documentation - https://developer.apple.com/documentation/foundation/file_system/about_apple_file_system

Since you are on Mojave or older, you don't need to worry about all the Catalina changes (yet) but here is the best listing of technical details on how this shared space using APFS containers will work for macOS in the future:

https://eclecticlight.co/2019/10/11/macos-catalina-boot-volume-layout-revised-for-10-15-release/

To return to your question, the only place you store files in in Macintosh HD - disk1s1, the other synthesized volumes VM, PreBoot, Recovery are for the system to store things it rebuilds and you don't need to back up as part of your normal use of a computer.


You can't do it natively, and you can't do it through an App Store app.

You'll have to jailbreak and search for a blacklist app on Cydia.

Of course you can disable SMS and/or MMS entirely on the device, but the iPhone and iOS is designed to have blocking enforced from the cell carrier and not the device. Until and unless your local carrier offers an iOS app so that you can self-block addresses, you'll need to modify iOS by jailbreaking to have SMS suppressed once they reach the iPhone hardware and software.


Can I sell a PDF through the iBooks store?

Apple has a support document that addresses this very topic:  Publish and sell books with iBooks Author

If you intend to put your books up for sale on the Apple Book Store, then they must be in the iBooks (.ibooks) or EPUB (.epub) format.  You will have to use iBooks Author for .ibooks.  For .epub you can use iBA, Pages, or various other apps.
If you intend to have a wider distribution outside of iBooks, then they must be in a different format than iBooks like PDF or EPUB.  If you go this route, you don't need to use iBooks Author; you can use the PDFs generated in Corel. One vendor for this is gumroad - https://gumroad.com/


What is different between itms vs itms-apps when opening url from device

Using itms-apps: will leads you to App Store directly.

Using itms: will leads you to App Store page in iTunes Store. You'll see "App Store" as navigation title and a button links you to App Store on the upper right corner.

I used to use itms: in my app. But I found that app status on iTunes Store was sometimes not up-to-date as App Store was. I haven't confirmed what caused this but now I use items-apps: instead.


Mavericks - User Account unavailable at login

Issue resolved. Had to RM the plist and recreate the account. No Firevault enabled.


How to erase and reformat SD card to ext3 on my macbook to prepare it for my raspberry pi

Install e2fsprogs brew install e2fsprogs
Format disk sudo $(brew --prefix e2fsprogs)/sbin/mkfs.ext3 /dev/diskN


Mail.app keeps crashing: Got EXPUNGE but EXISTS is already 0

I had the same problem, with it happening a few times a day but only when sending email. Rebuilding the mailbox did not help.

Eventually I found that I was storing draft messages on the server. This is picked in Mail > Preferences > someemailaccount > Mailbox Behaviours > Drafts Mailbox.

I changed that to a local "On My Mac" setting. I have not had a single error today and yesterday since doing so!

I think what was happening was my mail provider was sending the message and deleting the message from drafts, in the meantime, Apple Mail wanted to delete the message from drafts, and, they clashed depending on which happened first.


I actually believe I've found a fix for this.

I started greping through all the log files from when this issue started happening looking for a pattern. As it turns out the pattern is that the GoogleSoftwareUpdateDaemon runs everytime right before the crash happens:

Mar 30 13:33:55 <COMP-NAME> GoogleSoftwareUpdateDaemon[19078]: 2018-03-30 13:33:55.245 GoogleSoftwareUpdateDaemon[19078/0x7fff77030000] [lvl=2] -[KeystoneDaemon main] GoogleSoftwareUpdateDaemon inactive, shutdown.
Mar 30 13:34:00 localhost kernel[0]: Previous shutdown cause: 3

So doing some research, this is a updater that is secretly installed by Google (it is nowhere in their terms of service, nor is there a warning for it) what this does is update your Google applications every 5 hours. In order to disable this you can do the following:

defaults write com.google.Keystone.Agent checkInterval 0

What that command will do is set the interval for checking to 0. This is probably not recommended since security updates are important, so you can also set the interval for once a week:

defaults write com.google.Keystone.Agent checkInterval 604800

Now apparently this updater takes up very minuscule amounts of resources, but what they don't tell you is that it depends on how much Google software is on your system, it runs all the updates at one time. For example, if you have Google Chrome, Google Drive, and Google Hangouts installed, it will attempt to run updates for all of those pieces of software at once.

So what I did is the first option, set it to 0 and watched the computer for over an hour. Nothing happened, restarted and it boot right up, watched for another hour and it didn't crash or turn off. Going to assume this was the problem and move on with my life.


Safari is getting a download manager in iOS 13 which is due to release sometime later this fall.

iOS 13 Hands-on: Safari Finally Gets a Download Manager

New Safari Download Manager feature in iOS 13 will make you more productive


MBP with Touchbar install Debian 10 fails

Debian 10 comes with Kernel version 4.19.  According to State of Linux on the MacBook Pro 2016 & 2017

  Keyboard & Touchpad

  MacBookPro13,1 working MacBookPro13,2 working MacBookPro13,3 working MacBookPro14,1 working MacBookPro14,2 working MacBookPro14,3 working

  Works out of the box with Linux 5.3 and above.

  For earlier Linux versions you can get the driver from https://github.com/roadrunner2/macbook12-spi-driver.

Therefore you need either the patch or a distro with a more recent kernel (for example Arch Linux - the current iso has 5.3.1 kernel - or from next month Ubuntu 19.10).

If you want to use Debian 10 you should be able to install using external keyboard and then install the spi driver as described in the link above.


How can I limit the applications a user can access?

You don‘t need Applescript for this.

Open System Preferences
Create a new standard or Managed with Parental Controls user account for your brother
Enable Parental Control on this account
Limit access to the applications you want him to use


There are no utilities on the install disk that can help you. The "SMART Status" that is shown in apple's Disk Utility is completely useless. VERY rarely have I had a failing drive actually indicate it is failing in Disk Utility.

The best app for this is a utility called SMART Utility. It's not free but does have a free demo. They have an older version available that runs in 10.5.8 on PPC. You can get it here:
https://www.volitans-software.com/apps/smart-utility/

That will tell you if you have any reallocated bad blocks without needing to scan the disk. But you will have to have 10.5 installed on some volume and working in order to run that. Which means another internal drive or maybe a Firewire drive, or possibly a USB drive but that might not work.

As a mac repair professional, it is my primary tool for diagnosing failing hard drives.

If you want a utility that does actually scan the entire drive, I've found the best utility for that, believe it or not, it SoftRAID. Even though RAIDs in OS X these days are a whole big bundle of problems, that utility has a couple of different full-disk scanning and verifying tools that work very well. Although like I said, I almost never run them because SMART Utility is sufficient. Also SoftRAID is not free either although it also appears to have a free trial.


iMac 2017 - Apple Wireless Keyboard 2 and Magic Mouse 2 Bluetooth random disconnects

After spending numerous hours on the phone to Apple technical support, and tried just about every fix suggested here and on othe websites...

In the process I uploaded some system logfiles to Apple support and after a few more phone calls a Senior Apple technician confirmed that there is a known bug in Apple's Bluetooth drivers which should be fixed in the next patch for MacOS Mojave (which I believe will be 10.14.3). Hopefully this will finally resove the issue.


How to get a complete list of all applications installed?

Try:
About This Mac > More Info > System Report > Software

.

Not only "Installations" ... but the others may give you some info, too.


Use F1, F2 etc. keys to control built-in Mac features when using an external USB keyboard

The fn key isn't a modifier that's sent to the OS, it modifies the scan code that is sent.

To test this out, you can use a built in utility called xev (requires X11) to view the scan codes being sent from your mouse and keyboard.  You can also use Karabiner's Event Viewer to to obtain the key press scan codes.

What this means is that the scan code for F1 (130) will be different from the scan code of fnF1 (107).  Keep in mind that macOS allows you to "lock" the fn key to a particular behavior (have the function keys act as normal function keys or act as the "special feature keys").

This is different from other modifier keys (like Shift or Option in that both scan codes are sent (i.e. Shift A sends 64 and 8).

As for remapping a keyboard, you can use the built in utility hidutil to remap keys.  This answer here can guide you on how to do that.

Apple Developer Documentation Key Table Usage
USB.org Key Usage Table Reference (Page 53) (more in-depth source for Apple's Table)

This is a bit of a workaround for a simple keyboard, and my preference would be to just purchase a cheap keyboard with the fn key functionality built in so everything works out of the box.


Why are some PDFs scrambled when opened with Preview on Mac?

The PDF does seem to display incorrectly on Catalina, but not on other versions of macOS.
Preflighting the PDF in Acrobat flags several instances of fonts that are not embedded. Acrobat and other versions of macOS seem to be able to substitute the system Arial and Times New Roman, but Catalina does not. I'd suggest that is the bug.
Exporting from Acrobat as PostScript and re-distilling will produce a PDF that works in Catalina.
Exporting from Preview in another version of macOS will also produce a version that works in Catalina. (Exporting, not just Save As..)
Ghostscript produces a single blank page when trying to process the PDF.
The file was originally created using Acrobat 3, in 2001 on some Windows OS. While such systems should have been creating perfectly decent PDFs, something seems to have gone wrong here.


Yes you have to change your battery.

The Apple technician will confirm you it is beyond dead, as a dead spring (a battery is just a chemical spring with a finite life).


Help find what causes MBP reboot in 10.10.2

Assuming you have your Google Chrome on automatic updates, yours is the latest update version 40.0.2214.111

Why Chrome?

You crash report shows it as having problems causing other problems.

That should not crash your system, but only Chrome it self, but who knows.

What can you do?

Disable Chrome (for now) till Google comes up with a fix, and use another browser.


Is an iPhone call recorder theoretically possible?

On Jailbroken iPhones, SpoofApp does call recording. I am not a laywer, but note that recording calls may not be legal depending on where you are and/or where the other party is.


Is there a dashboard widget that displays Google Maps and traffic data overlay?

You can make one yourself using the unsung "Open in Dashboard..." command in Safari.

Open Google Maps in Safari. Adjust the size of the window so the map the size you would like the widget to be.
In Safari, go to the File menu, then "Open in Dashboard." You'll get a little hover in Safari. Place the cursor in the upper left part of the map so that the entire map, and just the entire map, is highlighted. It may be a bit finicky to get the map highlighted properly, so just keep at it and it will be fine.
Click add in the top of the browser. Done!

You now have a Google Map widget that acts just like Google Maps in the browser. Navigate to where you want to see traffic, enable traffic in the widget, and you're done.


The full backup does not include:

iOS itself (since that will already be on the other device),
app bundles (since they will be downloaded from the App Store again).

App data is backed up even if the apps themselves aren't. It's as full of a backup as is available and will back up all of your data.


What programs exist to find and delete "orphan files" left after deleting an Application?

If you are willing to use Terminal.app you can use find to identify files/folders which haven't been accessed for a long time.

find ~/Library/Preferences -atime +52w will list all prefences which haven't been accessed in the last 52 weeks.
find -d ~/Library/Preferences -atime +52w -ok rm '{}' \; will ask whether you want to delete it file by file

and if you don't want to get asked for each file, run

find -d ~/Library/Preferences -atime +52w -delete


Can I make snapshots of an APFS non-bootable volume?

TL;DR: Use the hypervisor's native snapshots, and never use APFS snapshots on a volume with VMs.

Carbon Copy Cloner is a good utility to manually manage APFS snapshots. Open the program, switch the UI from Simple to Normal mode (in the menu). In the volume table in the lower left of the main window, you can click on any volume and a pane opens that shows the snapshots, and lets you delete old ones. You can create snapshots by running a backup task - even a dummy one that copies just one file to some folder.

The problem is that when you have a disk with VMs on it, you should only ever use one snapshot mechanism: either APFS snapshots, or the hypervisor's snapshots, not both. I suggest that you never use APFS snapshots on any disk with VMs, and use the hypervisor's native snapshots. They are a much more mature technology.

The snapshots work by retaining all of the old data, so their effective size grows over time - no data after the most recent snapshot's timestamp is ever removed from the disk. If you use hypervisor snapshots on top of APFS snapshots, the space usage doubles and you will run out of space while doing things that should conserve space.

For example, start with a single 600Gb VM, with VMware snapshots, on a 1TB APFS volume. You want to delete a 200Gb snapshot from that VM: VMware will integrate the snapshot into the higher level disk image. The problem is that this will effectively write 200Gb of "new" data to disk - APFS doesn't have deduplication!! Thus, the APFS snapshot will have to preserve the previous state of those 200Gb's worth. You think you should reclaim 200Gb of space, but you end up using 400Gb more, and get a full volume.

At least on macOS 10.13, AFPS has bugs and APFS volumes that run out of space due to APFS snapshot activity become unusable. You won't be able to delete the APFS snapshots, nor do anything else on that disk. It's nominally read-only, all write attempts will be failing with a weird "permission denied" error. Your only recourse will be to make a backup of the disk, then erase/reformat it (How do I know? It just happened to me and it's totally reproducible).


Mojave doesn't remember window position/size for a specific application?

Here is the list of solutions:

Open a Finder window, hold down the option key and resize the window as you wish. Close all Finder windows and next time you open a new one it will remember the size.

Meanwhile, you can use an app like Stay to remember and automatically reset the position of any window.

You might also look at window managers such as Magnet that allow easy manipulation of windows.


Inkscape like tool in Mac with latex rendering capabilities

Inkscape is probably the best free option. I don't know of paid drawing tools that have LaTeX built in. LaTeXiT is great for generating LaTeX formatted math formulas.


Applescript Tell Application of Specific Instance

Scripting Bridge Approach

With ScriptingBridge, create an SBApplication instance with applicationWithProcessIdentifier: and then you can call the bridged AppleScript methods on the process of your choice.

  Overview

  Scripting Bridge is a technology that lets you control scriptable Apple and third-party applications using standard Objective-C syntax. Introduced in OS X version 10.5 (Leopard), the Scripting Bridge framework dynamically implements an Objective-C bridge to OSA-compliant applications—that is, applications having a scripting interface (usually defined in a sdef file). As part of this implementation, it generates Objective-C class implementations of the classes it finds in the scripting interface, including objects and methods representing properties, elements, commands, and so on. The objects are derived from classes defined in the Scripting Bridge framework.

AppleScript Approach

A discussion on MacScripter suggests this approach:

tell application "System Events"
    set myPID to unix id of process "TextEdit"
    -- ...for every matching process
    -- set myPIDs to the unix id of processes whose name is "TextEdit"

    set myProcess to first process whose unix id is myPID
    set the frontmost of myProcess to true
end tell

See also: How to activate Mac OS X application with a given process ID?


Why preview is showing a black box instead of an image?

I had a similar bit slightly different problem. I had whole pdf pages that were turned black when zoomed in and were correct when zoomed out, but the zoom made them impossible to read. I found this fix https://tidbits.com/2018/01/30/fixing-pdfs-whose-pages-render-as-black-rectangles-in-preview/ basically you have to calibrate your screen. i did it and it worked first time. odd.


What is the difference between on-the-go, save episode and download episode?

On-The-Go will create a play list which can be found under My Stations / On-The-Go.

Save Episode will save an episode that you've already played under the Saved tab.

Doing Download Episode, on the other hand, will actually start to download the episode and move it into My Podcasts list.

So, while On-The-Go and Save Episode is a way of organizing the episodes you've already downloaded, doing Download Episode actually downloads it.


osx port install of php74 crashes with Illegal instruction: 4

Here are the important parts:
Exception Codes:       KERN_PROTECTION_FAILURE at 0x00007ffeeccd3ff8

VM Regions Near 0x7ffeeccd3ff8:
    MALLOC_LARGE             7ff27e800000-7ff27f101000 [ 9220K] rw-/rwx SM=PRV
--> STACK GUARD              7ffee94d4000-7ffeeccd4000 [ 56.0M] ---/rwx SM=NUL  stack guard for thread 0
    Stack                    7ffeeccd4000-7ffeed4d4000 [ 8192K] rw-/rwx SM=ALI  thread

Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0   libsystem_kernel.dylib          0x00007fff2035068f __commpage_gettimeofday_internal + 31
1   libsystem_c.dylib               0x00007fff20266b6d gettimeofday + 45
2   libsystem_c.dylib               0x00007fff20282584 time + 48
3   php                             0x000000010292db7c tsrm_realpath_r + 384
    [...]
503 xdebug.so                       0x000000010551e540 xdebug_execute_ex + 1121
504 php                             0x000000010295e495 ZEND_DO_FCALL_SPEC_RETVAL_UNUSED_HANDLER + 405
505 php                             0x0000000102942ae7 execute_ex + 35
506 xdebug.so                       0x000000010551e540 xdebug_execute_ex + 1121
507 php                             0x000000010295e495 ZEND_DO_FCALL_SPEC_RETVAL_UNUSED_HANDLER + 405
508 php                             0x0000000102942ae7 execute_ex + 35509 xdebug.so                         0x000000010551e540 xdebug_execute_ex + 1121
510 php                             0x000000010295e495 ZEND_DO_FCALL_SPEC_RETVAL_UNUSED_HANDLER + 405
511 php                             0x0000000102942ae7 execute_ex + 35

Notice that you're at exactly 512 (= 2^9) stack frames and the parent frames have been truncated. You're getting a KERN_PROTECTION_FAILURE at 0x7ffeeccd3ff8 because you've overflowed the maximum stack size and you're trying to write to a protected region (the illegal address is just above Stack in the STACK GUARD region, which was created expressly to catch situations like this).
This happened because there was a highly recursive function call chain and it simply exceeded the 512 frame (8192 KB) default stack limit (see ulimit -s). From the looks of the recursed frames (ZEND_DO_FCALL_SPEC_RETVAL_USED_HANDLER() over and over), I'd guess that it's php code (either yours or the unit testing framework) which is recursing, rather than the C code of the interpreter itself.
If you aren't sure where the recursion is occurring, one temporary workaround would be to raise the stack limit of the php process using ulimit(1) and run your command again in the same Terminal window:
ulimit -s 65532
./phpunit --group Jobs_model

This will run your test with a 64 MB stack limit. Note that the kernel specifies a maximum upper stack limit of 64 MB:
#define DFLSSIZ         (8*1024*1024)           /* initial stack size limit */

#define MAXSSIZ         (64*1024*1024)          /* max stack size */

so if your recursion is way huge, you'll still run out of space. At that point, though, you would really want to find out what's recursing so much.


I would suggest the iFixIt kit and guide. It's gonna be expensive since unlike of the  the previous versions iPhone, on iPhone4 you can't just change the glass without the changing LCD..


Record video while playing TV on Jio Phone

Check out Record and Listen. Jamcam is great, but only records videos for up to 15 seconds.


On your iPhone, go to settings, general, date/time. Disable auto time zone and switch to another time zone. Then switch back to your own time zone (maybe wait a bit for the watch to pick up the change?). It will ask you again.


How do I remove grayed out phone number in send/receive in message settings?

According to Apple, all you need to do is sign out of your device

 Source: https://appleid.apple.com/account/manageCheck your iCloud preferences after signing out and back in.Settings › iCloud › User Account › Contact Information

If you are unable to remove/modify

Depending on your carrier, you may need to remove your sim and reinstall iOS.


Don't have macOS Big Sur yet; however, in previous version of macOS there is System Preferences > Users & Groups > you > Login Items, or use a Launch Agent. (I assume these methods are still available in macOS Big Sur.)
Have a look at:

Open items automatically when you log in on Mac

Creating Launch Daemons and Agents

See also the manual pages for launchd and launchctl in Terminal.

You can read the manual page for command in Terminal by typing command and then right-click on it and select: Open man Page

Update:
To refute the claim made by Vihung in a comment: "While you answer, in general, is correct, it doesn't apply to shell scripts"
The example AppleScript code, show below, used as a shell script with a #!/usr/bin/osascript shebang, and added to the Login Items tab of my account in System Preferences > Users & Groups, opens a new window in Terminal with an ssh session to another computer and automatically closes the original window that opened the ssh session in the new window.
This was tested under macOS Big Sur with Language & Region settings in System Preferences set to English (US) — Primary and worked for me without issue1.

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

Example AppleScript code:
      Note: Change ssh user@hostname to a properly formed ssh command for your required usage.
#!/usr/bin/osascript

tell application "Terminal"
    do script "ssh user@hostname"
    delay 0.5
    close window 2
end tell
tell application "System Events"
    tell application process "Terminal"
        tell its front window
            set i to 0
            repeat until (exists button "Terminate" of sheet 1)
                delay 0.1
                set i to i + 1
                if i ≥ 30 then return
            end repeat
            click button "Terminate" of sheet 1
        end tell
    end tell
end tell

Notes:
This requires Terminal to be added to: System Preferences > Security & Privacy > Privacy > Accessibility
It also requires System Events to be checked under Terminal in: System Preferences > Security & Privacy > Privacy > Automation

Note: The example AppleScript code is just that and sans any included error handling does not contain any additional error handling as may be appropriate. The onus is upon the user to add any error handling as may be appropriate, needed or wanted. Have a look at the try statement and error statement in the AppleScript Language Guide. See also, Working with Errors. Additionally, the use of the delay command may be necessary between events where appropriate, e.g. delay 0.5, with the value of the delay set appropriately.


Configure and personalise external keyboard buttons on Mac?

The first step might be to discover what key codes they are putting out. Key Codes will do this for you.

Then you will find that KeyRemap4Macbook will allow you to map those keycodes to something useful.


iPhone 6 Initial Power Up SIM Card Locking?

We don't know what you wound up doing or what happened ...

However, I will tell you that I recently obtained a Sprint iPhone 5 that had no SIM card and had never, ever been activated.  Apparently it was an Apple repair exchange, but the owner decided to move service over to Verizon rather than activating his exchange, and sold it to us instead when he found out Verizon could not activate it there.

I considered, like yourself, that perhaps the phone is in fact unlocked until the first SIM is installed.  So, I initially put in a U.S. AT&T SIM card instead.  That worked, and even displayed 4G service availability on the screen, until we got to the iTunes portion of the start up when the phone tries to verify itself with Apple and get the right carrier profile.  We received a message in iTunes that the "activation policy" does not allow using this SIM card unless Sprint unlocks the phone, and "this is not a hardware issue."

In my opinion, that is a pretty good indication that the phone is locked at the factory before any SIM is inserted, and also that it is possible for the phone to run even on AT&T within the U.S. if properly authorized (something Sprint denies).  As for whether the factory SIM lock includes international SIMs (your actual question), obviously we don't know from my experience, but I'd venture to guess it probably does as well, as in my opinion, the international unlock is a really just a partial SIM unlock which leaves the U.S. GSM carriers blacklisted.


How to create a Siri shortcut to play tunein radio on HomePod and Mac

I guess, I'm just missing the obvious solution. But for now, this is working for me:
Summary
A Siri shortcut executes an Apple Script on the Mac that starts the radio stream with the Music app and adds the HomePod as airplay output.
1. Apple Script to start the radio stream
On the Mac, create a script using the Script Editor application and save it e.g. to ~/play-radio.scpt.
# ~/play-radio.scpt
tell application "Music"
    set selected of AirPlay device "HomePod Kitchen" to true
    set selected of AirPlay device "HomePod Living-Room" to true
    play (every track of playlist "My Radio Playlist")
end tell

In the Playlist "My Radio Playlist", I've added the radio stream I want to start. I suppose, one could also add the radio stream's url directly. But this way, I can modify the playlist without re-opening the script again later.
2. Create Shortcut to execute the script
With the device that has been paired with the HomePod, e.g. the iPhone or iPad, open the Shortcuts app and create a new shortcut that is named after the desired Siri command, here: "good morning"

Add the workflow item Run Script Over SSH. Enter the hostname of the Mac and your Mac's user-account name. Choose "SSH Key" as authentication method. Add the command to execute the apple script:
osascript ~/play-radio.scpt

3. Import the SSH Key
If you haven't done so already, export the public SSH Key of the Shortcuts app by clicking on the SSH Key entry, share, and then air-drop it onto your Mac.
On the Mac, add the key to the file ~/.ssh/authorized_keys.
Attention! This will allow the Shortcuts app on your iOS device to ssh into your Mac.
4. Activate SSH
If you haven't done so already, activate SSH remote login on your Mac:

Go to "System Preferences"
Go to "Sharing"
Activate "Remote login"

Now the HomePod will understand "good morning" and execute the script, which will start Music on the Mac playing the radio station on the Mac and the selected AirPlay devices.


Is it possible to choose which macOS version to use when reinstalling?

When you boot to the Recovery mode option using Command-R, the Mac will restore the version of macOS which is currently installed on the Mac. Mountain Lion will be reinstalled if you use this key combination.

If you use Option-Command-R it will install the version of macOS that was originally installed on your Mac, or the closest version still available. If your Mac was purchased with Lion installed, Lion will be installed if it is available.

Apple Support information about macOS Recovery.


Toggle language by pressing Shift + Command

With freshest version (11.4.0 at 13.12.2017) of Karabiner Elements and Cmd + e for previous language source:

You can put this json gist to ~/.config/karabiner/assets/complex_modifications/<filename>.json, add gist rule in Karabiner Elements Preferences -> Complex Modifications -> Rules -> Add rule and Enable Languages -> Command + Shift to Command + e.

This will remap Cmd + Shift to Cmd + e and you can change language source by Cmd + Shift.


Why has my iPhone camera stopped focusing?

Since the phone is less than a year old, it will be covered by the default AppleCare warranty. I suggest contacting Apple, and they will probably just replace the phone outright.


I actually called Apple Support and they told me that it is not legal to sell an OSX version purchased in the app store.

The technically correct solution is indeed to (after backing up your data, unlinking the iTunes account and removing the mac from "find my mac" service) wipe the start volume ("Macintosh HD") and to do an internet recovery by pressing CMD+ALT+R on boot.

The error I encountered apparently was because of maintenance work on Apple's servers -- apparently sunday is not a good day to rely on them.

I was able to restore Lion on my MacBook without having to enter my apple id.

BTW: Internet recovery works, but is really slow, so be prepared for that.


How to disable the "Your computer time is almost up." dialog?

/System/Library/CoreServices/SecurityAgentPlugins/FamilyControls.bundle/Contents/Resources/English.lproj/FamilyControls.nib is a binary XML file that can be opened by TextWrangler or other text editors. This isn't a developed solution (yet), but I'd suggest some well-placed edits to this nib might be able to disable the dialog, perhaps by making buttons disappear. At any rate, this sounds more promising than randomly zeroing out portions of the binary using a hex-editor, which is the other channel I've been exploring.


Stuck at loading spinner after resetting iPhone 4 (iOS 7.1.2)

It sounds like something's gone wrong with the reset process, but you should be able to recover the phone without too much trouble.

First, open iTunes and connect the phone to your computer. If the phone appears in iTunes without displaying any error messages then you should be able to restore it from the iTunes interface.

If the above doesn't work you can force the device to turn off by holding down the Power and Home buttons until the screen cuts out. At this point you should be able to turn it back on and (at the very least) restore the device via iTunes.

If that doesn't work, try putting the device into DFU mode:

Turn off the device (if it isn't off already) by holding down the Power and Home buttons until the screen goes blank.
Hold the Power button for 3 seconds
Hold Home button without letting go of the Power button, then wait 10 seconds.
Keep holding Home and let go of Power. Wait about 15 seconds just to be sure.

(Source for the above: https://discussions.apple.com/thread/5409794)

From there the device will appear non-functional but you should have no problems restoring from iTunes.


Is it possible to use Ethernet connection on Mac without battery draining?

It might be possible that some software is using up battery power. It can be checked in Activity Monitor under the Energy tab.
Under same app usage, ethernet adapter consumes more power.

The Ethernet dongle can be using up to 2.5 watts, that's 2500mW.....native ethernet connections typically use a lot less, but the dongle to ethernet requires MORE power, ..hence more power out when using the AIR thru the ethernet dongle.
Wi-Fi in GENERAL consumes between 10 mW and 800 mW (transmitting full bandwidth); NATIVE Wired ethernet consumes 200mW to 1W

Source: https://discussions.apple.com/thread/5194898


How to open path in Double Commander from Terminal

By default Double Commander is programmed to open with two Tabs each set to the current location of the Double Commander.app application bundle.  If one then changes to a different location other then the default on one of the Tabs and then closes Double Commander and reopens it, it opens to the last location before being closed.

Here's a way to open Double Commander to a specific path from the command line similar to opening Finder to a specific path using Terminal.  This covers the default of two Tabs.

Use the following syntax in a Terminal:

open -a Double\ Commander --args -path location ...

Example:

open -a Double\ Commander --args -path ~/Documents

This will open Double Commander to your Documents folder in the left Tab and the right Tab will open to the last location opened.

If you want to set the location of the both Tabs use:

open -a Double\ Commander --args -path location location

Example:

open -a Double\ Commander --args -path / ~/Documents

This will open Double Commander to the root of the boot volume, typically Macintosh HD, in the left Tab and your Documents folder in the right Tab.

If there is a way to set just the right Tab while letting the left Tab default to the last saved location I do not know the syntax for it, if it's even doable.  I did try several attempts using different delimiters but none gave the wanted results in testing.

Update to address the comment by s.newave:

I'd add a function to your .bash_profile file as in the following example code:

function odc () {
        pkill doublecmd; open -a Double\ Commander --args --no-splash -path "$1" "$2"
 }

Then from the command line in Terminal you can simply use odc or e.g.: odc / ~Documents

Note that if the Double Commander > Configuration > Behaviors > [] Allow only one copy of DC at a time, check box is not checked, you can use the following variant to open a new occurrence of Double Commander to the desired paths leaving other occurrences of Double Commander running.

function ondc () {
        open -n -a Double\ Commander --args --no-splash -path "$1" "$2"
 }

Then from the command line in Terminal you can simply use ondc or e.g.: ondc / ~Documents

Note that in either case you can also pass a single argument as well, e.g. odc ~Documents or: ondc ~Documents

The function names odc and ondc stand for open double commander and open new double commander, respectively.


Bizarre message whenever I open my calendar

It is possible that you are trying to access a calendar link that was created before Google changed their URL formats (which was a long time ago). Old Google calendar links started with
https://www.google.com/calendar/dav/

Back in 2013, they changed the URL format to
https://apidata.googleusercontent.com/caldav/v2/your-email

I would suggest that firstly, you should delete any subscribed calendars (e.g. things like the "Public Holidays" calendar. If the problem persists, the next step would be to remove your account from the calendar app entirely, close the calendar app, then reopen and re-add your account details.
Make sure you've backed up your data first.


At first you should disable Photo sync in iTunes. When you open iPhoto, you should be able to select your iPhone on the left side (assuming it's connected to your Mac). Then you can select all pictures you need and import them (you will even be asked if they will be deleted from your iPhone after the import). This way the iPhone should not sync photos like it ususally does with iTunes (when enabled).

See this Apple KB article: Copying personal photos and videos from iPhone, iPad, or iPod touch to your computer

EDIT: You have to do this manually. I don't know if it's possible to do this automatically when syncing with iTunes.


How do I get Samba volume to mount automatically at bootup?

You could also add the alias as a Login item: go to System Preferences > Users & Groups, and click on Login Items. You can then drag a mounted network drive, or a drive alias, into the Login Items list.


Is it now possible to spy on other person's iPhone using microphone?

I think the incorrect part of your question is the word 'spy'.  No, it's not possible to spy or listen to an iPhone's microphone without a notification or without the users consent.

I'm not a developer of these apps but I am an iOS developer with a few apps in the App Store so I'm familiar with the iPhone's API's and App Store review process.  Apple does not provide a way to secretly listen to another device

From reading their product page description, the 'listening' is done using a chat application or Messages.  The app starts recording and then sends the recording to the parents via chat.  It might work different in Android but for iOS that's what it looks like it's doing.  The image below specifically calls out "Android/GPS watch".

There doesn't appear to be anything 'secret' or in violation of Apple's app guidelines in these apps.  The wording on the app's App Store description is vague regarding how they do what they claim.


I've come across bugs like these that ended up being intended or unintended side effects of Chrome extensions or flags. Try disabling these first to make sure it's not one of these.

To disable extensions:

Go to chrome://extensions/.
Uncheck Enabled for each enabled extension.
Reload the buggy pages.

To disable flags (developer options):

Go to chrome://flags/.
Click Reset all to default on the right.
Click Relaunch now at the bottom of the page.

Disable these one by one until the problem goes away, so that you can not only fix the problem bug but also figure out what caused it in the first place.


kernel_task consumes 500% CPU on AC power, sometimes

In my experience this has always been due to a hardware fault. However before doing anything else reset the SMC as detailed here: http://support.apple.com/kb/HT3964 as its power related.

This appears to happen when the Mac is struggling to communicate with hardware. Which Mac is it? How old is the battery? Is your battery life still good? Has the Mac had any damage - dropped? Liquid? Have you tried a different power adapter?


Are you on OS X 10.7.4 ?
Then an explanation and possible solution might be found here on CNet:

Tackling SMC console errors after OS X 10.7.4 update

"Might", because it didn't work for me - even after uninstalling iStat Menus v2.x, so it must be some other application(s) on my part that is causing this...


How can I install Office from disc on iMac without SuperDrive?

If you can put your iMac on the same local network as another Mac with a CD-DVD drive, it should be possible to configure the two of them so that your iMac can share the CD-DVD drive on the other Mac.

Other than that, you would need to purchase or borrow an external USB CD-DVD drive and plug it into your iMac.


Terminal Sub-pixel Rendering improvement?

In OS X El Capitan 10.11 Terminal was changed to use minimal font smoothing for light-on-dark text, which more closely matches the weight of dark-on-light text with normal smoothing intensity, and makes the text sharper and more readable, opening up counters like the hollow space in the letter “e”.

A natural consequence of this is that light-on-dark text can appear less bright than before. Users can adjust colors in Terminal’s preferences if they wish.

UI controls (NSControl) do the same, but the standard OS X text view (NSTextView) does not, so programs like TextEdit and Xcode still draw light-on-dark text with more intense font smoothing.

“…is there a way to apply this in other applications as well?”

Without some hackery to modify individual applications, they are only affected if they use standard Cocoa controls and text views.


El Capitan "Paste and Match Style" not working in Microsoft Word

When I try ctrl+v

Command+V

Try to delete and add one again.

It works for me (macOS Sierra, Safari):


Disable network device for specified period of time

Selfcontrol

Selfcontrol is an app build for a different purpose, it disables your network connectivity for a certain amount of time to keep you from visiting social websites and keep you more productive. It makes it possible for you to create a white-list or a black-list to allow or block certain ip-adress/sites.

So I login to the server, set Selfcontrol to 1h. Now my internet connection from my server is disabled for 1h and will automatically come back afterwards.


Is there an app that allows users to take multiple photos and upload them all together?

Why yes - the iOS photo picker has been modal for some time now and allows one picture to be selected by apps that use the long time iOS API to access the camera or the picture roll and albums.

Furthermore, copy and paste is also a single item and there is no clipboard history functionality in iOS.

I suppose a jailbroken device could be modified - but I don't know of any apps or work to actually do that, so this is a theoretical capability to my awareness.

You can use the Photo all (and the new iPhoto app as well) to send multiple photos to email or a message. In that case, you can email these multiple pictures directly to a Posterous Spaces account that you have set up using the Posterous app. Twitter has purchased Posterous recently and announced that the service will not be shutting down immediately and that users will have an export tool and notice should the service get shuttered in the future.


Does Profile Manager support nested device groups?

Yes.

The problem was that a process on the server or the client did not like one of the settings payloads in the "outer" group (Directory in my case).


Option-Delete deletes word with white space in front

I select the entire space and word as per your example. Then keeping Shift and Option pressed, I use the left arrow to select the empty space. Works like a charm and is only one extra keypress.


iPhone Accessory warning - without any accessory

I think the problem is caused by circuit shortening on the iPhone dock connector. This means that the iPhone detects some kind of an accessory is connected (pin shortened), but cannot verify that it's genuine. Try cleaning it with compressed air.


Apps will not open, post OS X Mavericks update

I'm having the same issue on two of my machines. None of the core apps will launch (Mac App Store, Maps, Message, Photobooth, etc.).

One solution that worked for me for a short period of time:

If you hold Command+R on restart, it activates the recovery partition from which you can reinstall OS X Mavericks.
Unfortunately the "fix" doesn't last for long and you're either forced to rinse and repeat, or give up entirely.

There doesn't seem to be a genuine fix anywhere online that works for me.


Quit Messages
Open Activity Monitor, find the process called "Dock", then hit the top left "X" icon to force it the Dock process to quit. The dock should disappear and then reappear.
Reopen Messages. Your unread count should be reset!


After you install any of the apps published by Google on your iPhone, it can determine whether you have the other Google apps installed on your iPhone by using the following API call available in iOS:

canOpenURL: - UIApplication

Based on this, it could be determined what apps you do not have installed on your iPhone, and Google can suggest you to install them.

An iOS app can be assigned a custom URL scheme by it's developer. It's using URL scheme that your iPhone is able to directly launch say for e.g. YouTube or Google Maps app if link for the same is tapped in any of the other apps.

This specific instance isn't necessarily a privacy violation as Google is simply using one of the APIs made available by Apple. When it comes to apps, Google is just another 3rd-party app publisher on iOS and has to adhere to same privacy restrictions like every other developer.

P.S.: While it could be argued that Google's privacy stance is not as strong as Apple, they are bound to adhere to restrictions imposed by Apple as they are no different from other 3rd-party app developers for iOS and generally do not get any elevated privileges.


It depends on the application, but a program like TextEdit, that you mention, names unsaved documents as "Untitled xx" where xx is a number. You can then search for that name to recover the document from backups.

For example on many systems the untitled document would be saved in:

~/Library/Mobile Documents/com~apple~TextEdit/Documents/Untitled xx.rtf

If you have a Mac where the system has been shut down, and open windows have been auto saved, and you're looking at the disk from a different Mac for recovery, you'll find the auto saved window information in:

~/Library/Containers/com.apple.TextEdit/Data/Library/Saved Application State/com.apple.TextEdit.savedState

However, those files are not immediately readable as RTF files. The easiest way to restore them is to place them there on another Mac, and then start up TextEdit to restore them.


iPad and iPhone can sync with each other on Notes -- how about adding info on the Mac or PC?

In Lion, iPad and iPhone notes that are synced through your mail account can be accessed and edited in Apple's Mail app.


How to extend the functionality of Open and Save dialogs of OS X applications?

Step one - try the free trial of DefaultFolderX (30$).

Step two - buy it.

These is no step three. It's that good.


ssh -A doesn't properly enable forwarding of authentication agent connection

Actually, the very simple answer is that you have to run

ssh-add

and then it all works.

Basically, macOS already has the ssh-agent set up for you, but after each reboot you need to add your keys to it. ssh-add gives ssh-agent access to your keys for the current boot cycle.  You'll have to enter the password for your private key if you have created one.


Clicking "Downloads" in Finder does nothing. How can I repair it?

I can think of two different ways to address this:

Method A)

Remove the "Downloads" icon from the side bar (hold the cmd key, drag it out of the side bar)
Navigate to your home folder, and drag the "Downloads" folder back to the side bar

Method B) Caution: this will completely reset any changes you made to the Finder sidebar

Go to your user's "Library" folder (in Finder, hold the "Alt" key, and and pull down the "Go" menu at the top of the screen. You should see "Library" as one of the options)
In ~/Library/Preferences folder, move "com.apple.sidebarlists.plist" to the Trash
reboot (or log out of your account, and then log back in again)


Can't open Firefox because a copy of Firefox is already open

Here is what I did to fix the issue:

In OS X Terminal, find your currently used Firefox profile directory (something like):

$ cd ~/Library/Application\ Support/Firefox/Profiles/
$ ls -l

if you have multiple profiles, list the one with the most recent date

$ cd rAnd0m.default
$ ls -la

remove the hidden parentlock file

$ rm -v .parentlock

try to start Firefox again

(If the problem was not related to the parentlock file, you will see:
rm: .parentlock: No such file or directory)

If you prefer to use the Finder, just make hidden dot-files visible first, so you can check for the existence of .parentlock and delete it.


iTunes home sharing, between 2 iTunes accounts, but 2 way?

You can use separate iTunes accounts, but the HomeSharing account must be the same. You will need to authorize each other's computers/devices with both iTunes accounts in order to play back content purchased under the other account.


To where is the Catalina installer saved?

It should be in the global /Applications folder. By default all App Store downloads go there. It's been that way for years.


You'll need to make your own bootable DVD/USB of the Lion installer to do so. This can be made from the AppStore download and is documented well by OSXDaily.

Lion USB Installer
Lion DVD Installer

Then hold ALT at system boot (before chime & Apple logo) and select your install volume.


mvim (MacVim 7.4) opening new windows rather than tabs (Mac OS X 10.8.5)

use the --remote-tab command line switch, as in:

mvim --remote-tab foobar.txt

The answer was obtained by reading help:mvim it is located in section 14 of the help file titled macvim-hints.

Extracted here is the relevant section of the MacVim 7.4 help file:

  Scenario:

  ~ You want to open a file in a tab in an already opened
   window, but typing "mvim filename" in Terminal opens it up in a
   separate window.

  Solution:

  ~ Use the |--remote-tab| switch.  If you
   have several windows open you might have to specify which window you
   want the file to open in by using the |--servername| switch.  The
   title of a window usually ends in something like "VIM" or "VIM3" ---
   this is the server name of that window.  So to open a file named
   "foobar.txt" in a window whose title ends in "VIM3" you would type
   (the order of the arguments matters):

  mvim --servername VIM3 --remote-tab foobar.txt

  For more information, consult the |client-server| manual page.


1 - Open Automator and create a new Service:

2 - Set the Service to receive Files and Folder in Finder:

3 - Drag an "Ask for Finder Items" action:

4 - Drag a "Run AppleScript" action:

5 - Paste this code:

on run {input}
    set numItems to count input
    set theFile to item (numItems) of input as text
    set numItems to numItems - 1
    repeat while numItems is not 0
        tell application "Finder"
            duplicate file theFile to folder (item (numItems) of input as text) with replacing
            set numItems to numItems - 1
            delay 0.1
        end tell
    end repeat
    display dialog "File copied to all folders" buttons {"Thanks"} giving up after 5
end run

6 - Save your workflow and name it as you want:

7 - USAGE:
Select as many folders as you want, right click, services, find your workflow:

Select the file you want to copy (beware the window can be hidden behind the main one):

Click "Choose" and wait for the copy.

PS: the file will replace existing ones with the same name.


Why is there a generic folder icon for Library in the "Go" menu?

Unfortunately, there is no Sidebar icon for the Library folder in Yosemite and El Capitan. The sidebar icons are used for the Go menu items as well.

The icon that was used in the past in the  (Mavericks and before), was (to my knowledge) ToolbarLibraryFolderIcon.icns, which does not exist anymore.

You can view the Sidebar icons that do exist in /System/Library/CoreServices/CoreTypes.bundle/Contents/Resources. They are named in the format Sidebar<FOLDERNAME>Folder.icns.

Interestingly, the Library folder icon (for the folder itself in Finder) does still exist, as LibraryFolderIcon.icns


Safari 6 keeps suddenly crashing on Lion

A common reason for an application crash is a corrupt preference file. The first thing you'll want to try is backing up and deleting your preference file for Safari.

Close Safari, and then you can find the preference file by going to ~/Library/Preferences and looking for the file called com.apple.Safari.plist. Once you've found the file, back it up by adding a tilde to the front of the file name so it becomes ~com.apple.Safari.plist. Once you restart Safari, it will generate a new .plist file.

If that doesn't work, the next step would be to do a permissions repair using Disk Utility, which you can find in /Applications/Utilities.


Setting Work Schedule with Outlook an half hour boundaries

That is a limitation of the Outlook.

I use a work around.

I have set up a repeating event 7-8:30 for every work day, and marked it as "out of office" status, and Private and named it "do not disturb".

At least in the view now my work day starts at 8:30, and no one can call me in a god forsaken way to early meeting.


Can I enlarge the EFI Partition? And if so how?

I used Rod Smith answer and comments @ https://superuser.com/questions/1142967/can-i-enlarge-mac-efi-partition-and-if-so-how and understood that the EFI partition does not have to be the first partition on the drive.
So basically I performed the following procedure:

Marked the EFI partition as normal data partition
Created another 500MB partition, marked it as EFI
Installed the OS and moved the boot.wim to the new EFI and let the deployment procedure complete
After the deployment completed I marked the old partition back to EFI and deleted the new partition I created, and voila! the OS deployed successfully and the drive returned to its original state


How to enter internet credentials using terminal?

The short answer is "Yes."  You can enter your credentials within Terminal.  You have to use the networksetup command

That's if you can get to terminal...  If you can, then the following will help get you connect.  But, if you can't, scroll down the bottom for an alternate...

However, you have to have a create an 802.1x profile for which to connect to your network.  This is as straight forward as just entering in a username/password

Here is the man page for the networksetup command on Apple's website: https://developer.apple.com/library/mac/documentation/Darwin/Reference/ManPages/man8/networksetup.8.html  You can view this in Terminal by typing man networksetup

Since you mentioned plugging in your Ethernet, it's safe to assume you are using 802.1X Port Based Authentication.  Basically, there is a server, most likely a RADIUS server, but possibly another type of  AAA server (authentication, authorization, and accounting) that allows your computer onto the network.

Basically, before you are allowed to go anywhere, the network is checking to see if your device is authorized to connect, to where you can go, and (who/what) should be charged (if applicable).

So, how do you set this up?

This can get a little complex, so normally the IT department will supply you with a config file for you to import.  You would do so with the command networksetup -import8021xProfiles Ethernet <filename of profile to import>

From what I have seen, you need OS X Server to create the profile, however, it is not hard to edit one once it has been created.  Here's a link to one created for the SMU network:  https://blog.iphoting.com/blog/archives/817-Lion-Wireless-Access-in-SMU.html

Disclaimer:  Don't expect SMU's profile to work in your environment.  It is most likely configured completely different than what your environment is configured for.

Alternate Method

Use another computer and share the Internet Connection

You can use virtually any other computer (Apple, Windows, Linux) to connect to your institutions network whether it be wireless or wired.  Once you have that computer up and running, just share the Internet connection.

Since this is an Apple thread, you can use this example as a basis for sharing Internet.  The connection is WiFi, but it is exactly the same for Ethernet.

If both your computers are connected to Ethernet, you will need a USB to Ethernet adapter and a crossover cable (or a switch).  The onboard Ethernet on the working computer will go to the institution network, the USB to Ethernet adapter will go to the computer you are trying to connect.

Once you have the working computer function, you turn on Internet sharing which effectively turns it into a router.  You can then connect to the Internet on the computer you are trying to boot into recovery mode.


I can't download garageband sounds I purchased

The issue has been resolved try downloading again.

Source: Apple Support


How to turn on "Hey Siri" when plugged in, but not always on

"Hey Siri" is now always on, if on, because of the new M9 co-processor; the same one that records your steps. Apparently it can do this without unnecessarily flattening the battery.

See the report from Apple Insider - Apple's efficient M9 coprocessor will let your iPhone 6s track pace, make 'Hey Siri' always on

  In a first for the iPhone series, the iPhone 6s will measure a user's walking or running pace when they exercise, without the need for battery draining GPS. Previously, this functionality was limited to the S1 chip in the Apple Watch.

  The M9 also allows for Siri to be always on. That means users will be able to use the device's "Hey Siri" voice command at all times.


Does Time Machine take advantage of two backup disks to backup more fine-grained snapshots?

Time Machine will continue to perform hourly backups, rotating through your backup drives. Each drive will contain a full, independent backup of your source drive.

This provides redundancy for your backup system, if that is what you seek. In case one of your backup drives fails, you still have another. This can prove particularly useful if you keep one of those backups offsite (backing over the Internet will require special setup, however, and can prove agonizingly slow).

The ability to use multiple backup drives was introduced starting with OS X 10.8 (Mountain Lion).


Your birthday will be private. Read the privacy policy if you're concerned about it.

If your birthday appears in your calendar, it's probably because your birthday has been added to your private card in Address Book. There's an option to show birthdays in Calendar. However the birthdays are only showed to you, not your contacts.

Beware of entering an erroneous birth date. Apple can ask you your birthday to verify you're the actual owner of the Apple ID for security purpose. So if you enter a false birthday, be sure not to forget it.


Restored iPad , old Apple ID, find my iPhone still on

If the account is truly deleted and you can no longer login, you'll have to contact Apple for them to remove the lock for you. You'll probably need to show proof of purchase, ID or similar.


What displays are capable of displaying full resolution from the new MacBook Pro with retina display?

There are all sorts of high end specialized displays that have this resolution for the medical, government imagery, and engineering markets.

http://en.wikipedia.org/wiki/Graphic_display_resolutions

You can see any Hyper XGA display exceeds 2880 by 1800 (but are not shipping as single monitors yet) and most Quad XGA displays (shipping since 2001) exceed the "15 inch retina" in terms of sheer pixels on one display panel/monitor.


What does a darker grey arrow in finder represent?

This is simply a glitch. The darkened triangle is used when the button is pressed. It doesn't mean anything about the folder and will be fixed by closing and re-opening the window as you discovered.


The Absinthe tools are really easy to use - jailbreaking has gotten much easier than it used to be. However, the dev teams are hard at work on getting their tools to work with the latest iOS version/chip version combinations so it's hit or miss with if you will actually be able to do it.

Absinthe is currently only compatible with 5.0.1 and 5.1.1 (you can see greenpois0n.com for a bit of info).

One thing to look out for is that it can be confusing but being that you have a 4S that narrows it down a bit - you will probably need to wait until they update Absinthe to jailbreak, unless you are fortunate enough to not have updated the firmware yet.

On the subject of unlocking, that's a different story - in case you're not sure of the difference, unlocking means being able to use different carrier SIM cards where as jailbreaking means being able to use non approved apps (it's a common mistake, so that's why I mention it here).

Unlocking can be done a few different ways (in the US, I'm unsure exactly the process in other countries). In the US, Sprint WorldWide customer service will unlock your phone if your account has been in good standing for 90 days (I've had 5 iPhones unlocked this way) and as long as there are no other holds on your account. AT&T will unlock a 4S that isn't on contract (I'm unsure if it has to be an AT&T phone originally) and I think Verizon Wireless has a similar policy (but I don't know for certain).

One thing you will want to watch out for are street vendors that say they can unlock your iPhone - they can't, don't waste your money.

iClarified actually has a pretty good walkthrough wizard for both unlocking and jailbreaking here:

http://iclarified.com/unlock/index.php (unlocking)

and

http://iclarified.com/jailbreak/index.php (jailbreaking)

Hope that helps.

Cheers!


DRAM compatibility between two early 2011 MacBook Pro

Yes, the two are compatible. It doesn't matter if you have the 2720QM or 2820QM CPU.  You can swap the RAM modules without any problems.

The GPU (graphics) has no influence on which memory module is compatible. You can swap the RAM modules no matter which of the two models you have.

The 13" version will also be able to use the same RAM module.


You can’t remove the primary email address associated with the account. You can set another one as the primary, but the first email address that you use to create the account with cannot be changed ever. Not even by calling Apple. I tried. Eventually, I created a dummy gmail account to get my invoices and stuff. Once an email address is verified, there is no way to “unverify” it.


Your device should "just work" on a Mac. To use adb to connect to your device you do it as usual, meaning you would have to install the android SDK for mac, then enable debugging mode on your phone, and use the Terminal command-line app as you would on the Windows command-line.


For non-startup drives, the disk is encrypted with a single password and is not linked to a user account or iCloud, nor does it generate a backup key. Admin users are required to enter the same encryption password as any other user.

The best suggestion would be to ask the other person to unlock the drive or give you the drive password, which they may or may not be inclined to do.


See https://everymac.com/systems/apple/macbook_pro/macbook-pro-retina-display-faq/macbook-pro-retina-display-13-how-to-upgrade-ssd-storage.html for a lot of  details about how to upgrade the internal disk of a MacBook Pro, including information about compatible drive models and instruction on how to actually replace the drive.

It probably goes without saying, but make sure you have a good backup before you start.


How can I rename a folder in Lion's Launchpad?

Ok, I did a google search and came across a page where others are having the same problem.

The reply by etresoft - https://discussions.apple.com/message/15661045#15661045 - basically says to kill the Dock application and it should restart automatically, and then it should work.

I did that, started Activity Monitor, found Dock, and force-quit it, it started right up again, and afterwards renaming worked as expected.


You can troubleshoot El Capitan the same as any other OS X - boot in verbose mode to see a specific log of what is happening so you now the exact area in the boot process when it's failing.

Or you could install 10.11 on to a fresh, new USB drive and get a test that confirms your hardware isn't the problem since a clean install should boot properly.

https://support.apple.com/en-us/HT201573 - How to start up your Mac in single-user or verbose mode
https://support.apple.com/en-us/HT201262 - Try safe mode if your Mac doesn't finish starting up


I also noticed screensaver problems after installing a USB-DisplayLink adapter on my Mid 2012 MacBookPro.  Except my problem is that periodically screensaver kicks in even though I've been typing and mousing.  There are screensaver error messages in /var/log/system.log but I'm not sure they are related to this issue.

All screens except the DisplayLink screen blank out.  FWIW, I use a USB keyboard almost exclusively, and wonder if that is part of the problem.


Downloading this Google Chrome 64-bit version 39.0.2171.2 - you get the correct one.


Automated Deletion of Messages From OS X Mail

Okay, so I've found a solution using AppleScript, it's a fairly big script but it's not actually all that complicated; it simply loops through the mailboxes of every count, skipping any specified in a list, and looks for read, undeleted messages older than the specified number of days.

 on run arguments
    # Don't run if Mail isn't open
    if application "Mail" is not running then return

    set defaultExpiryDays to 45
    set dryRun to true

    # Standard deleted message mailboxes, used to relocate mail when "deleted"
    set trashMailboxes to {"bin", "trash", "deleted messages", "deleted items"}

    # These mailboxes will be ignored (messages won't be processed)
    set ignoreTheseMailboxes to trashMailboxes & {"all mail", "archive", "archived", "drafts", "junk", "junk e-mail", "sent", "sent items", "sent messages", "spam"}

    set numberOfArguments to number of items in arguments
    if numberOfArguments is greater than 0 then
        set expiryDate to item 1 of arguments
        if number of arguments is greater than 1 then
            set ignoreTheseMailboxes to ignoreTheseMailboxes & rest of arguments
        end if
    else
        set expiryDate to defaultExpiryDays
    end if
    set expiryDate to (current date) - (expiryDate * days)

    set countdown to 10
    repeat while countdown is greater than 0
        try
            return processMail(expiryDate, ignoreTheseMailboxes, trashMailboxes, dryRun)
        on error number -1712
            set countdown to countdown - 1
        end try
    end repeat
    return "Communication with Mail timed out"
end run

on processMail(expiryDate, ignoreTheseMailboxes, trashMailboxes, dryRun)
    set messagesDeleted to 0
    set messagesMoved to 0

    set results to {}
    set newline to "
"

    tell application "Mail"
        set theAccounts to every account

        repeat with eachAccount in theAccounts
            set accountName to name of eachAccount
            set accountNameWritten to false
            set accountTrashMailbox to false

            set theMailboxes to every mailbox of eachAccount
            repeat with eachMailbox in theMailboxes
                set mailboxName to name of eachMailbox
                set mailboxNameWritten to false

                if ignoreTheseMailboxes does not contain mailboxName then
                    set theMessages to (every message of eachMailbox whose (deleted status is false) and (read status is true) and (date received is less than or equal to expiryDate))
                    set mailboxResults to {}
                    repeat with eachMessage in theMessages
                        try
                            if accountNameWritten is false then
                                set the end of mailboxResults to accountName
                                set accountNameWritten to true
                            end if
                            if mailboxNameWritten is false then
                                set the end of mailboxResults to "  " & mailboxName
                                set mailboxNameWritten to true
                            end if

                            # Find this account's trash mailbox (if we haven't already)
                            if accountTrashMailbox is false then
                                repeat with mailboxName in trashMailboxes
                                    set foundMailboxes to (every mailbox in eachAccount whose name is mailboxName)
                                    if number of items in foundMailboxes is greater than 0 then
                                        set accountTrashMailbox to first item of foundMailboxes
                                        exit repeat
                                    end if
                                end repeat
                                if accountTrashMailbox is false then set accountTrashMailbox to missing value
                            end if

                            if accountTrashMailbox is not missing value then
                                set the end of mailboxResults to "      Moved:  " & (subject of eachMessage)
                                if not dryRun then move eachMessage to accountTrashMailbox
                                set messagesMoved to messagesMoved + 1
                            else
                                set the end of mailboxResults to "      Deleted:    " & (subject of eachMessage)
                                if not dryRun then delete eachMessage
                                set messagesDeleted to messagesDeleted + 1
                            end if
                        end try
                    end repeat

                    if number of items in mailboxResults is greater than 0 then
                        set AppleScript's text item delimiters to newline
                        set end of results to mailboxResults as rich text
                    end if
                end if
            end repeat
        end repeat
    end tell

    set messagesMatches to messagesDeleted + messagesMoved
    if messagesMatches is greater than 0 then
        set statistics to {}
        set AppleScript's text item delimiters to ""
        if messagesDeleted is greater than 0 then
            set the end of statistics to (messagesDeleted & " message(s) deleted") as text
        end if
        if messagesMoved is greater than 0 then
            set the end of statistics to (messagesMoved & " message(s) moved") as text
        end if

        set AppleScript's text item delimiters to ", "
        set the end of results to (statistics as text)
    else
        set the end of results to "No messages were deleted."
    end if

    set AppleScript's text item delimiters to newline
    return results as text
end processMail

The script deletes messages by locating an account's trash folder (if it has one) and moving them, which is a very slow process if it has a lot of e-mails to move initially, however it prevents the need to rescan. It will only use the regular delete option if it can't determine the trash folder (i.e - didn't find one from the names in trashMailboxes), while this is faster it may result in messages being reprocessed if the script is run frequently (e.g - daily).

To configure the script's setting you can change defaultExpiryDays to the number of days of e-mail to keep, everything older and read is deleted. The dryRun setting is set initially to true, which means the script will report matches but won't actually delete or move anything, once you're happy the script is matching the e-mails you expect it to then you can set this false.

The trashMailboxes lists the mailbox names that the script will move e-mail to if found for an account. The ignoreTheseMailboxes list contains mailboxes that shouldn't be processed, and covers most common ones, including folders that Mail's normal mailbox behaviours should cover already.

The script can be run by anything that can trigger an AppleScript, such as iCal, in which case it will use its defaults. It can also be triggered via a shell script or launchd using a command such as osascript /path/to/script.scpt, which will likewise use the defaults, or you can specify additional arguments in which case the first is the number of days to keep, and any further arguments are additional mailboxes to skip, for example osascript /path/to/script.scpt 14 foo bar will keep the last two weeks worth of read e-mails, and will skip any mailboxes named "foo" or "bar" in addition to the defaults.

If you want to automate the process with launchd then you can create a file under ~/Library/LaunchAgents with the extension .plist, and contents such as:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>Label</key>
    <string>org.example.Mail.Clean</string>
    <key>ProgramArguments</key>
    <array>
        <string>osascript</string>
        <string>~/path/to/script.scpt</string>
        <string>45</string>
    </array>
    <key>EnableGlobbing</key>
    <true/>
    <key>StartCalendarInterval</key>
    <dict>
        <key>Minute</key>
        <integer>15</integer>
        <key>Hour</key>
        <integer>13</integer>
        <key>Weekday</key>
        <integer>0</integer>
    </dict>
</dict>
</plist>

Which will keep 45 days worth of e-mails, and will run every Sunday at 1:15pm (remember to set the path to your script under program arguments!).

Once saved the launch agent will then load either next time your shutdown/restart, or you can run launchctl load ~/Library/LaunchAgents/agent.plist with the correct name for your plist file.


What is it about 3G that kills the iPhone battery?

The 3G radio requires more power. If you live in a weak 3G signal area, it may also cycle a lot between EDGE and 3G; setting up the 3G connection draws more power. Finally, you may be able to save power by setting the iPhone to Fetch New Data less often (Settings > Mail, Contacts, Calendar > Fetch New Data).


How to delete Voice Memos on macOS Mojave?

Slide the recording to the left to access the Delete button, or continue sliding to delete instantly.

Alternatively, choose Edit, select the recording to delete, then choose Delete.


Will a new keychain be synchronized over iCloud?

This keychain will remain local. Only keys/certs/etc in the iCloud Keychain will be synchronised over iCloud.