Shutdown Script in macOS / RAM Disk Backup

Regarding your comparison with Linux: Mac OS X did indeed have the "rc" system, you know from Linux (it is really called a SysV init system). Back in 2005 this system was abandoned with OS X Lion, and the more modern launchd system was introduced instead - leading to, amongst other things, much faster boots.

On Linux the same change has happened, however later than on macOS. Nowadays Linux distributions commonly use systemd, upstart or similar "modern" take on an init system.

Regarding your solution - it is really a hack, and it not done the right way. This is why you're having issues. You're trapping both SIGTERM and SIGKILL - this is against recommendations, and it is the cause of the "No such file or directory" error message.

Basically what happens on shutdown (this is completely similar to Linux) is that each process is sent SIGTERM to let it know that it should terminate. The process then only has a very short time to close (i.e. within few seconds) - otherwise the system sends the SIGKILL signal to really kill off the process if it is not responding.

In your case when the copying takes a bit too long, you'll trap both signals and you will run your shutdown() function twice.

You haven't included your launchd configuration (i.e. probably a daemon plist), but you need to be careful to have dependencies and orders configured here in order for your hack to work. Otherwise you risk the RAM disk being unmounted before shutdown is called (which is probably what happens when you run shutdown the second time due to the SIGKILL signal.

As far as I remember the /etc/rc.shutdown.local file is still a valid method to run programs at shutdown. This is by far the easiest way of doing it.

Simply create the /etc/rc.shutdown.local file and make it executable. It should start with a shebang like your current script, but only needs to contain the commands you use to copy over the files to your backup.

If you want to do it properly with launchd you could either modify your hack to handle signals properly, and then use the xpc_transaction_begin/end functions to let the system know that your program is doing useful work, and shutdown should be delayed until finished -- or alternatively use the event trigger functionality in launchd.

I would recommend you to try /etc/rc.shutdown.local first. It is deprecated, but as far as I remember still working.

A small warning is probably also a good idea for you. Remember that you are never guaranteed that your shutdown program will run. It is therefore not a good idea to keep stuff you don't want to loose in a RAM-disk like that. A single power outage and your data is lost. Instead use frequent data synchronisations or similar to ensure that data is periodically backed up to permanent storage.

Regarding your request whether a better approach exists - then the answer is "most likely, yes". The idea of copying a web folder to RAM disks seems a bit historic and dated. We have not information about what you're doing with that web folder, but if you're just serving web sites and want it to be fast by using a RAM-disk - that is the wrong approach. It is much better to use the built-in vfs caching functionality of macOS (similar to any other modern operating system, such as Linux).


Another solution I found to this problem:

Open Settings -> Phone -> Show Caller ID

It'll take some seconds to load the and show a loading indicator, after that is done the phone will be able to make and receive calls


How to fix iPad Pro complaining about unsupported Apple Smart Keyboard?

The Smart Connector (three small pins) on the Apple Smart Keyboard is not forming a clean connection with the corresponding three-pin socket on the side of the iPad Pro.

Here are some ways to fix it:

Clean the contacts on the keyboard and iPad Pro
Remove the Keyboard, restart your iPad Pro, reconnect the keyboard

More info can be found on this Apple Support document:
https://support.apple.com/en-gb/HT205237

However, this technique worked for me (it is not mentioned on the Apple support site):

Remove the Smart Keyboard
Put your thumbs on the plastic ridge behind the contacts on the
Smart Keyboard
Gently push the Smart Connector outwards with your thumb, and with your fingers pull the ends of the plastic ridge on Smart Keyboard towards you so it slightly bends the ridge (moving the smart connector outwards).
Reconnect the Smart Keyboard

I did this and it formed a better connection between the Smart Connector on the keyboard and iPad Pro.

This technique fixed my Smart Keyboard and prevented the "Accessory not supported" error from appearing.

Images here showing the push and bend in my keyboard:
https://www.flickr.com/gp/185452511@N03/m444o6


Turning off iCloud sync w/ Photos on Mac threatens to delete local files

You enabled a feature called "Optimize Mac Storage" where low-res photos will be stored locally on your Mac, but the original resolution photos will be stored in iCloud. So when you are disabling sync, iCloud choses to delete the low-res photos on your Mac, and keep them in iCloud.

Method 1: Contact Apple support, or walk into an Apple store and ask them for help.

Method 2: Try finding and disabling the feature I mentioned in the first paragraph. The alternative is called "Download and Keep Originals. This will only work if you have enough space on your device. After you disable that feature, disable iCloud Photo Library

Method 3: You should try downloading all the photos currently stored in iCloud and put them in the same (create a new folder) folder as the ones that have not been uploaded (make sure they are original resolution, as a back up). Make sure there are no duplicates. The number of photos should add up to the total number of photos you had(2,073 in your case). Then just disable iCloud Photo Library. Then just delete all the photos in your Photo Library, and put all the pictures that in the backup you created earlier into your photo library.


iMovie doesn't support Graphite appearance?

I believe "that graphite look" you refer to is merely the color scheme that Apple uses for its "Pro" applications to distinguish them from its consumer level applications.

iMovie is a perfectly good (if limited in what it can do) application that can be used quite successfully to edit and finish up home or amateur video projects. If you need some features that iMovie does not offer you can switch to Final Cut Pro or Adobe Premier


If you do not have iOS 4.0 or don't use folders, or if you are using an older version and do not have the jailbreak app Categories, the maximum amount of pages of apps it will display is 9 pages. 9 * 16 = 144 apps. You can still find the other apps in the search option, on the leftmost page, if you use iPhone OS 3.0 or newer.


Does SMS Forward to Mac work if iPhone is turned off?

No, iPhone has to be turned on in order for SMS messages to be received by it and then forwarded to your computer, or for you to send messages, which are sent back to the phone and then out to your carrier from there.


Do iOS Contacts work with Prius car navigation systems?

BT Phone/Address systems use different Bluetooth "Stacks" or APIs. You have to check compatibility for each one at the mobile vendor's site or through third party enthusiast sites. Sadly, this level of detail is often beyond your average auto parts department because as an extension of sales they will simply say, "Yah, sure. It's Bluetooth, it'll work." For example our 2005 Prius could not speak Apple Address Bluetooth, but our 2012 Chrysler can.

Sadly, you won't get much milage (pardon the pun) out of hacks and jailbreaks because it comes down to the low level Bluetooth (sometimes at the chip level) that the equipment uses.

Also, to be an iOS compatible BT device, the device has to go thru the process of MFI certification.

So, again. you'll have to call your auto support line and in the case of the Prius; prepare for disappointment.

In the case where you have been able to exchange address book entries, you will likely need to make sure that the address book entry is in the right format. (Country, state, label, etc) Again... check with expert forums on that.

In the case of a Prius, I stongly recommend: PriusChat


Upgraded to OS X EI Capitan and my Canon MG2240 will print but not Scan

It sounds like you may need to install software to run the scanner, which Canon seems to call "software" instead of "drivers."

This link will take you to the page where you can select what looks like a safe download. (Note: this link does NOT initiate a download.)

Just scroll down to the Scan Utility.


Why is there no bootable disk found when using windows install disk?

i hade this problem a few times it's because os x somehow can't set the axtive flag which is needed by the bios/efi tho know at which disk thy should overgive the bootloader.

so you need to set the partition as active by hand via Terminal

Go to finder/Spotlight, and launch Disk Utility
Select the usb disk, and create a partition. Format it as MS-DOS FAT and select Options > MBR
Go to the Terminal, and type the following

diskutil list

locate the name of your usb device. In my case it was rdisk2. Depending on your OS version it could differ.

diskutil unmountDisk /dev/rdisk2

Make the partition active and unmount the disk

sudo fdisk -e /dev/rdisk2
print
f 1
write
print
exit
diskutil unmountDisk /dev/rdisk2

have a look here for a colorful howto: http://tech.anoj.net/2013/01/fixing-unetbootin-on-mac-os-x-to-create.html?m=1


Would this loophole for stolen MacBook Pro Retina work, or can macOS detect this and stop it?

No.  The firmware lock prevents even this.  Firmware doesn’t reside on the drive, it resides in a protected “memory” (not RAM) area that holds the boot, encryption, management, etc. software.

In fact, if you want to test it, set an EFI lock and remove the drive.  Then try to boot.  You’ll notice that the password is still there

  As someone who carries my MacBook Pro Retina on me at all times, and plans on a somewhat pricey upgrade to a newer model sometime in the future, I'd like to ensure I can make this thing a glorious paperweight for any would-be thief.

You’re in luck because the new Mac computers with the T2 chip take security much further with Secure Boot and whole disk encryption.  Once these features are enabled, would  be thieves would end up with great looking paper weights.


I run into same issue: At work I have to use Windows and at home I use a Mac. I'm sick of having different shortcuts for these basic tasks. Here is my solution for it:

Go to your User folder on your Mac and open the Library directory.

Here you create a "KeyBindings" folder.

Then navigate into that folder:
(Your User folder)/Library/KeyBindings/

Create a file "DefaultKeyBinding.dict" with following lines:

"^v" = "paste:";
"^c" = "copy:";
"^x" = "cut:";
"^z" = "undo:";

Save everything and restart your Mac.

Now, you will have CTRL + x/c/v/z working like it is on a Windows machine.

This will change the behaviour for page down as requested by MadBoy.


MacBook Pro resale value -- should I replace the battery?

I think if the rest of the laptop is still in good condition, then replace it.

For one thing, it leaves a bit of a bad impression with a potential buyer. You're giving them a machine which works only with the plug and if they wants to use it on battery they'll have to go out and work it out with Apple himself. Personally I'd expect a pretty hefty price reduction for that.

If you replace it on the other hand, you can clearly state so in the description (eg "battery was recently replaced for $120 and should now allow you to work for a full X hours while not plugged in" or whatever) which actually increases the price and the value of the laptop.


Any way to trigger Folder Action when adding file to any subfolder?

You should take a look at an amazing app called Hazel, from Noodlesoft which will trigger even AppleScripts to folders.


Mac mini Problem - Won't boot after upgrading to High Sierra (Bless)

If you startup with the USB drive again, try to use the Disk Utility (available pre-install) to set the Startup/Internal Drive ("blessing" it).


Terminal command to bring up shutdown dialog?

You can send loginwindow the kAEShowShutdownDialog Apple event:

osascript -e 'tell application "loginwindow" to «event aevtrsdn»'

The four letter codes for Apple events are listed in AERegistry.h. See this answer for more information.


Can I set up Contacts phone numbers format

International Numbers

To store international numbers in the Contacts app (without changing the whole phone in regional settings), you need to enter the country code when adding the number... and it will format it according to what is expected for that country.

Examples

Entering a standard US number, such as 3135551212 produces (313) 555-1212.

Entering the country code first, such as +13135551212 produces +1 (313) 555-1212.

For a Mexican phone number, entering +526241234567 produces +52 624 143 1234.

Etc... etc.    The trick is to use the plus symbol, plus the country code, in front of any international number.

Extensions

For extensions, the general rule is that you use a pause, or wait, in the phone number when you add it.

For an extension number that you type immediately after dialing the number, use Pause. This adds a “,” to the phone number.

For a prolonged pause (like when the IVR goes on for a while before asking you to choose a number), use Wait and then key in the number.


The situation is like that: Applications can use the syslog(3) API and the asl(3) API to log messages, other data logged can come from the kernel or from the network. All of these messages are handed over to the syslog Daemon: syslogd(8). The syslogd now outputs log messages both the BSD way (it writes stuff into various basic log files like /var/log) and into a unified log message store (/var/log/asl.log).

If you want certain log messages not to appear in your log files (eg. you read logs like system.log by selecting them in Console.app), you will need to configure syslog.conf(5) like chiggsy said. If you want messages not to be stored in the asl database, you will need to configure asl.conf(5).

If, for example, you do not longer want Bonjour's (mDNSResponders) Log messages to be stored in the ASL db, you will need to add the following line to /etc/asl.conf :

? [= Sender mDNSResponder] ignore

… and then "gently" restart the syslogd by:

sudo killall -HUP syslogd

Now, messages from mDNSResponder will no longer appear when you go into Console.app's "all messages", but still exist within your logfiles.

Lastly, if you call syslog(1) from the command line, it acts as a nice frontend for querying the ASL db - you could for example ask it to show all messages from the Time Machine Backup starter that were logged in the last two hours by running:

syslog -k Facility -k Sender com.apple.backupd-auto -k Time ge −2h

…which explains, why the ASL db is handy: you can search for log files simultaneously in "all log files".


Backing up Time Machine to an external disk also used by other machines - no sparsebundle?

The sparsebundle is how Time Machine backs up using the network method. The Backups.backupdb method is how it backs up when the drive is hooked up locally therefore you can't make it create a sparse bundle if its connected locally because that's the way time machine works. If you want it to make a sparse bundle you have to backup through a network. It should not make a difference to you since you'll be accessing it through time machine without having to worry about files etc.


How to make menu-bar auto-hide/appear faster?

If by menu-bar you mean the dock, you can disable it.

Under System Preferences you'll find a submenu for Dock settings


Can I retrieve Apple TV purchases made on my spouse's account?

Using Family Sharing in iOS8; otherwise only by signing in to her account.

Sharing purchased content with Family Sharing


Renaming a populated iMac Snow Leopard external HDD a possibility?

Select the drive (just like any other file/folder) and press enter, and rename it just like any other file/folder


How do I move my Outlook mac files to Ms outlook 2010?

This depends a little bit how the outlooks are connected to the mail server.

When you use an Exchange Server, you don'T have to do anything. You just configure to keep all mails online in the server. Then you connect with Win Outlook and can access your email.
Another option is to exports all mails from MAC Outlook. And open this export in Win Outlook.

ciao
ryder


The word "Ports" here does not mean what you think it means. It is not the number of a single TCP or UDP port the process has open. It is not even the count of such ports.

'The "ports" column shows how many "Mach ports", or "kernel queues" the process has open, which basically describes how communicative the process can be with others (eg: reserving memory usage from the system). This information will only be useful to system administrators and programmers.'


Some clarifications about Messages.app in Mountain Lion

There are several things going on here. First, and easiest, Bonjour just appears as an option that you can configure if you have a Bonjour account. No need to worry about that.

As for iMessage, you can have more then one email address that other iMessage users can message you at. For example, when I open Messages settings I have a few different accounts in there. Bonjour is disabled, and two Google Talk accounts which I have disabled also. When I click on my "iMessage" account, my iPhone number as well as several email accounts which are linked to my Apple ID show in there. So I have my Gmail (which I use for my Apple ID), my @iCloud.com and @me.com email accounts, as well as two others that I have arbitrarily added in so that other users can text those emails as well.

Messages.app on Mountain Lion can manage multiple types of instant message at one time. For example, I can have a Jabber account, Google Talk account, and my iMessage account all tied into Messages. When someone "pings" any of those accounts, Messages "handles" that and I can reply.


Running 10.7.5 server but would like to remotely manage it with a 10.8 macbook pro

According to the Apple Web site:

Lion Server
To administer Lion Server, use Server app and the Server Admin Tools 10.7 on OS X Lion. The Server Admin Tools 10.7 are are available from Apple Support Downloads.
To administer Lion Server from a client with a different version of OS X, connect to the server using Screen Sharing or Apple Remote Desktop. You can also use Workgroup Manager 10.8 on Mountain Lion to connect to Lion Server.

One alternative to what Apple suggests is to run a VM of whatever OS you need to use to do remote management. This is what I do on my laptop with Lion. I don't have the same luxury with Snow Leopard, although I guess I could virtualize an instance of it, and run it on the desktop side as well.


What is the easiest way to move images, clipboard, links from iOS to a Windows PC and vice versa?

Im using Shareit - free app for iphone + free program for win. Works very fast. Only of course have some adverts as free version.


How to I protect my jailbroken iPhone/iPod Touch/iPad?

On a general level, I'd personally secure a jailbroken phone by re-enabling the code signing restrictions of iOS, ensure sandbox requirements are upheld and turn off all remote access. Furthermore, disabling all root accounts and choosing secure passwords for all remaining accounts that your specific jailbreak process creates or modifies would be prudent.

Apple has teams of people to police third party apps, set up sandboxes, audit security, etc… When you jailbreak, you take responsibility for all of those activities which carries a large technical burden to know what to check in the first place and then how to secure things.

At some point, this exercise becomes a bit metaphysical  - Do you trust Apple to engineer and watch the device? Do you trust yourself to be up on securing unix systems (Practical Unix and Internet Security, 3rd Edition is a fabulous book)? Do you trust the jailbreak to document what changes it has made and allow you the control over security you desire?

There are clearly times when a jailbroken phone (in the hands of a knowledgable operator) can be more secure than Apple's current iOS if it patches a vulnerability that you need to have closed now and not when Apple patches it - but for most, sticking as close to Apple's configuration as possible is the best plan from a security stance.


It depends on which model of iMac it is as the various models have differents types of RAM - for example DDR2, DDR3, LPDDR3 and LPDDR4. In particular make note that some models use LPDDR RAM, where the "LP" stands for Low-Power.

The latest mid-2017 iMac uses PC4-19200 DDR4 SO-DIMM RAM modules. Here the difference in power usage between 8 GB and 16 GB is approximately 3 watts.

The difference between in power usage in having 1 x 16 GB, vs 2 x 8 GB, vs 4 x 4 GB modules is negligible.

Note that the mid-2017 27" iMac consumes about 217 watts when the CPU is maxed out, so the RAM power usage is very small compared to the rest of the system.


Resizing or expanding a CoreStorage volume

After gaining some experience with CoreStorage volumes, I reworked my first answer to generalize and facilitate it by adding some scenarios and deleting some dispensable steps.

Basically there is one undocumented command to resize or expand a CoreStorage volume group and an inherent logical volume:

diskutil cs resizeStack LVUUID size

The command expands or shrinks the whole CoreStorage Volume Group including the physical volume(s), the logical volume family and the logical volume in one step to the desired size.

While shrinking it down to the size of the occupied space in the logical volume shouldn't be problem at all (but not recommended because at least 10% free space should be left), any blocking partition except the recovery partition has to be deleted or diminished before expanding the CoreStorage stack.

The command comes in handy in several scenarios:

expanding a CoreStorage volume after deleting a 2nd old-style JHFS+ volume on the same device (this may happen after splitting your disk in two partitions in Mavericks and then updating to Yosemite. The first partition - your system volume - might be converted to a CoreStorage volume, while the 2nd volume is left alone.)

expanding a CoreStorage volume after manually deleting a Boot Camp NTFS volume

resizing a CoreStorage volume to create 2nd old-style JHFS+ volume on the same device

Beware: The command is vastly undocumented and as such potentially destructive.

Preparation:

Backup your data.
Detach any external drive (especially your external Time Machine backup drive).
Restart to Internet Recovery Mode by pressing alt cmd R at startup.
The prerequisites are the latest firmware update installed, either ethernet or WLAN (WPA/WPA2) and a router with DHCP activated.
On a 50 Mbps-line it takes about 4 min (presenting a small animated globe) to boot to a recovery netboot image which usually is loaded from an apple/akamai server.

I recommend ethernet because it's more reliable. If you are restricted to WIFI and the boot process fails, just restart your Mac until you succeed booting.

Alternatively you may start from a bootable installer thumb drive (Mavericks or Yosemite) or a thumb drive containing a full system (Mavericks or Yosemite).

Modify CoreStorage stack:

Open in the menubar Utilities/Terminal

First you should get an overview of your disks and the partition layout:

Enter diskutil list
Example listing:

/dev/disk0
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                        *68.7 GB    disk0
   1:                        EFI EFI                    209.7 MB    disk0s1
   2:          Apple_CoreStorage                         53.7 GB    disk0s2
   3:                 Apple_Boot Recovery HD            650.0 MB    disk0s3
   4:                        EFI No Name EFI            100.0 MB    disk0s4
/dev/disk1
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:     Apple_partition_scheme                         *1.3 GB    disk1
   1:        Apple_partition_map                         30.7 KB    disk1s1
   2:                  Apple_HFS OS X Base System        *1.3 GB    disk1s2
/dev/disk2
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:                  Apple_HFS System                 *53.5 GB    disk2
/dev/disk3-disk12 ...belong to the OS X Base System (your recovery system you booted to previously)

Disk0 is your main internal disk device containing the EFI-partition (dis0s1), the CoreStorage partition (disk0s2) and the Recovery HD (disk0s3).
The No Name EFI (disk0s4) only exists if you had a Boot Camp partition previously and deleted it manually.

Disk1 is a logical disk created by booting to the netboot image which contains a recovery system (OS X Base System = disk1s2) similar to the Recovery HD.

Disk2 is also a logical disk residing in disk0s2 and it contains the CoreStorage stack.
Enter gpt -r -vv show /dev/disk0
Example listing:

gpt show: /dev/disk0: mediasize=68719476736; sectorsize=512; blocks=134217728
gpt show: /dev/disk0: PMBR at sector 0
gpt show: /dev/disk0: Pri GPT at sector 1
gpt show: /dev/disk0: Sec GPT at sector 134217727
      start       size  index  contents
          0          1         PMBR
          1          1         Pri GPT header
          2         32         Pri GPT table
         34          6
         40     409600      1  GPT part - C12A7328-F81F-11D2-BA4B-00A0C93EC93B
     409640  104974016      2  GPT part - 53746F72-6167-11AA-AA11-00306543ECAC
  105383656    1269536      3  GPT part - 426F6F74-0000-11AA-AA11-00306543ECAC
  106653192     204800      4  GPT part - C12A7328-F81F-11D2-BA4B-00A0C93EC93B
  106857992   27359703
  134217695         32         Sec GPT table
  134217727          1         Sec GPT header

The partition with the index number 1 is the regular EFI-partition, the partition with index number 2 is your CoreStorage partition and the partition with index number 3 is your Recovery HD.
The partition with index number 4 (=No Name EFI) only exists if you had a Boot Camp partition previously and deleted it manually.
All the rest is unallocated free space (in the example 27359703 blocks à 512 B).
Enter diskutil cs list
Example listing:

  CoreStorage logical volume groups (1 found)
|
+-- Logical Volume Group A629E051-D7B0-4B8C-A803-074F62704636
    =========================================================
    Name:         System
    Status:       Online
    Size:         53946696192 B (53.9 GB)
    Free Space:   16777216 B (16.8 MB)
    |
    +-< Physical Volume 90C09FC0-4215-4871-901B-70E2C9C7D464
    |   ----------------------------------------------------
    |   Index:    0
    |   Disk:     disk0s2
    |   Status:   Online
    |   Size:     53946696192 B (53.9 GB)
    |
    +-> Logical Volume Family F6962E38-50E4-4458-BFE6-CF2E179352F5
        ----------------------------------------------------------
        Encryption Status:       Unlocked
        Encryption Type:         None
        Conversion Status:       NoConversion
        Conversion Direction:    -none-
        Has Encrypted Extents:   No
        Fully Secure:            No
        Passphrase Required:     No
        |
        +-> Logical Volume BD36C73D-860D-4DC6-B125-AD624F448B88
            ---------------------------------------------------
            Disk:                  disk2
            Status:                Online
            Size (Total):          53496696192 B (53.5 GB)
            Conversion Progress:   -none-
            Revertible:            Yes (no decryption required)
            LV Name:               System
            Volume Name:           System
            Content Hint:          Apple_HFS

to resize the CoreStorage volume you have to delete any blocking partition first (the Recovery HD doesn't count because it usually will be moved with the resizeStack command).
First you have to unmount all mounted volumes on disk0 (first the CoreStorage volume, which has its own disk identifier disk2 but resides on disk0, then all other mounted volumes on disk0 - check this with df):

diskutil unmountDisk /dev/disk2

then additional volumes (if you have any at all). Example:

diskutil unmount /dev/disk0s5

If you have a NoName EFI partition delete it by entering:

gpt remove -i 4 disk0

Remount any previously unmounted volume in the reverse order with

diskutil mount /dev/disk0s5
diskutil mount /dev/disk2

Since any blocking partition is deleted you may now resize the CoreStorage volume with

diskutil cs resizeStack LVUUID size

with LVUUID: UUID of the logical volume and size: the final size of your CoreStorage volume.
Examples:

diskutil cs resizeStack BD36C73D-860D-4DC6-B125-AD624F448B88 60g

to expand it to 60 GB

diskutil cs resizeStack BD36C73D-860D-4DC6-B125-AD624F448B88 40g

to shrink it to 40 GB

diskutil cs resizeStack BD36C73D-860D-4DC6-B125-AD624F448B88 0g

to expand it to the full available size (0g is a magic number here).

Your Recovery HD should be moved automatically - regardless of whether shrinking or expanding the CS volume - to the very end of it.
In case of shrinking the CoreStorage volume you may now create a 2nd partition with gpt.
Enter the following to get the new partition scheme:

gpt -r -vv show /dev/disk0

and

gpt add -b StartBlock -s NumberOfBlocks disk0

to create a new partition. StartBlock is the number of the first block in the unallocated space and NumberOfBlocks is the number of free blocks or smaller. NumberOfBlocks has to be dividable through 8!
Enter exit and quit Terminal.
Open Disk Utility (and format your newly created partition if you have created a new partition in the second last step).
Then check your expanded CoreStorage volume for errors.
Quit Disk Utility.
Reboot to your main volume.


BetterTouchTool

With BetterTouchTool, you can create a Magic Mouse action to middle-click, such as this:

For trackpad users, BTT gives you the option to perform a 'special' middle click designed for CAD users (accessible through Advanced → Action Settings → Settings for Predefined Actions → Use special middle click mode).

  This allows people who work with CAD software etc. to perform a real middleclick using the trackpad. Use predefined action middleclick in combination with "three finger click" gesture. Click with 3 fingers then release two of them and move the remaining finger to drag the view around.


how to add few music files to iPhone which is "manually managed" by a different PC?

If you are manually managing via iTunes, there is no way to just add some songs to your iOS music library without deleting what is already there.
There are a couple workarounds that are only slightly unpleasant.

Use a iOS ripping software like the one by iSkySoft to copy the music from your iOS device to the computer, add that to the iTunes library of whatever computer you have, then sync all of that plus the new stuff. [40% unpleasant]
Put the songs in a cloud service like Dropbox or Box to store, and listen using the appropriate app. [10-25% unpleasant]


Why Does CalendarAgent Access Strange Domains?

I would say because those links are on calendar.google.com and Calendar app is following the links for some reason. When I go to calendar.google.com in a browser it has links for play and feed burner and translate.


Applescript IF statement with click and keystroke?

I don't know any way to do that with AppleScript, but you could add something like this to KeyRemap4MacBook's private.xml:

<autogen>__PointingButtonToKey__ PointingButton::MIDDLE, KeyCode::SHIFT_L</autogen>

See the source for the key code values and predefined settings.


IPhone app to block callers at specific times?

Do Not Disturb can do that, no 3rd party app needed.

You might have to juggle a new contacts group, because it only allows to receive calls from one group at a time, or favourites - so to exclude 'work' you might need to create a new group containing 'everyone else'

You can also toggle it manually from the Lock Screen


How to tell whether apps are "running" on iOS

No, there's no way a regular user can tell the current state of an app.

Apple can change the state of an app at any time depending on a number of circumstances.  None of those circumstances should be of any concern to a user.


MacBook Pro 15" 2010 keyboard won't work in login screen - Yosemite

Try this...

Start your Mac from the recovery partition. Once it's booted, go to the Utilities menu item and select Terminal. Type in the following command (substituting the OS X startup disk name if different from Macintosh HD)...

rm /Volumes/"Macintosh HD"/Library/Preferences/com.apple.HIToolbox.plist

...and then restart your MacBook.


Cannot install OS X from OS X Utilities on early 2008 Macbook Air

Not every mac is eligible for an internet recovery:

http://support.apple.com/kb/HT4904


Do you have a custom PS1 that is overriding the prompt from the theme you have selected?

Check you don't have any additional lines in ~/.zshrc beyond the default?

Backup your .zshrc
Delete all lines beyond export PATH=$PATH:/…
Reload your Terminal

Do you have any plugins that are messing with things?

Check ~/.oh-my-zsh/custom/plugins/ for any additional plugins.
Remove all your plugins from your ~/.zshrc and reload your Terminal.

Check you don't have any additional lines in your ~/.zprofile?

mv ~/.zprofile ~/.zprofile-bak

…and reload your Terminal. (Put back with mv ~/.zprofile-bak ~/.zprofile)

Note: trapd00r and linuxonly show the same errors for me


Symlinks became files, containing relative paths, within an app bundle, why? How to fix?

You might have been using Apple network-transport protocols, but the underlying file-system your server uses is not HFS or APFS, and probably isn't n-fork capable either. Symlinks in both of Apple's file-systems rely on inode referencing, and if the file-system doesn't have some form of compliance capability then items with metadata as fork references and inode lookups doesn't really have much chance of surviving intact.

This is why non-app-store software is often distributed in .dmg format, because they are a wholly self-contained island of Apple compliance stored as a single contiguous data-block, allowing it to pass through hostile servers and deadly file-systems with impugnity.

That's the cause – as for detection, only trying to run the suspect to see what happens. macOS installers are vastly complex, the bigger the app the greater the chance they'll rely on internal symlinking and thus the higher the possibility that they're now little more than useless bytes .... because you can't repair apps that have been damaged in such a manner.

Prevention: Turn apps & installers back into .dmg files (with a handy drop tool like QuickDMG for archival purposes.


why my mac opens with do not disturb mode although I didn't schedule?

Open the terminal
Type killall NotificationCenter

This fixed it for me. I've found the solution on this reddit thread.


What do these marks indicate exactly on these tray icons when I run Python from a terminal?

The short arrow is indicating alias. Some like that are also there in my Applications folder for apps which are located in ~/Library folder.

So I can guess that when first photo's original process is done, alias is still active. This happens to me while using OpenCV. closewindow() is hard to perform. I have to force quit it every time(it kills jupyter server too), or reuse the window.


iOS Spotlight search for, then edit a contact

From your second screenshot, 3D Touch on the profile photo, then tap on the name at the top of the popup to open the contact in Contacts.app.

Without 3D Touch, this is not possible. To search contacts, you can use the Search bar at the top of the Contacts or Phone apps.


How to use Telnet with Personal Hotspot (tethering)?

OK, I found one solution that works great.

Since the connection between the computers was originally wired with a router, I plugged them both into the router.

Then I removed the default gateway settings from the wired connection. This prevents them from going to the internet via the wired connection.

But, they are both connected to iPhone by wireless or USB (a separate wired connection), so they go to the internet through iPhone. The first time it takes the computer about 10 seconds to figure this out.

The caveat is that you need 2 interfaces for each device and a way to connect separate from iPhone.


How can I zoom in TextEdit without breaking word wrap/wrap to window?

In Finder, locate the file and use quicklook cmd + space and pinch to zoom.


If you think it's a discoveryd issue and 10.10.4 can't come too soon, might as well make it come now! Go to this Apple link and sign up for the public beta program, where you'll be given a link to download a piece of software that'll get the App Store to pick up beta updates. Take a backup of everything, install Beta Access Utility, and then install and enjoy a discoveryd-free Yosemite!


Can an alias be added to the dock via the command line?

Definitely scriptable with terminal commands.

/usr/libexec/PlistBuddy -c "Print" ~/Library/Preferences/com.apple.dock.plist

Shows you the actual configuration for the dock.

Within the above file you need to modify the "persistent-others" array if you want to create a "file" alias.

This is done the following way:

/usr/libexec/PlistBuddy -c "add:persistent-others:0 dict" ~/Library/Preferences/com.apple.dock.plist

If you want an application alias you will need to modify the "persistent-apps" array.

Once you make the changes and you are testing you need to do:

killall dock

to refresh the dock.


How do I change my health app from a bar graph to a line graph?

Simply the answer is: you can not change because of the update


Mac OS X 10.4 - Thunderbird 3 to Thunderbird 13

It seems that installing Thunderbird 3 on a newer Mac--non PowerPC--is the correct way to go about it.

I'll refer to the older Mac as "machine 1," and the newer Mac as "machine 2."

Find an archived installer for Thunderbird 3.
Install Thunderbird 3 on machine 2, and launch it.  Do not answer any questions, and quit Thunderbird: this will generate the appropriate folder structure in ~/Library.
On machine 1 locate the applicable profile in ~/Library/Thunderbird/Profiles/, and copy it over to machine 2.

I archived it with tar -cf ~/Desktop ~/Library/Thunderbird/Profiles/profile so it transferred faster, and saved a copy to our fileserver.

On machine 2, place the profile in ~/Library/Thunderbird/Profiles, keeping in mind that in Mac OS X Lion ~/Library is hidden in Finder.

Extract the profile with tar -xzf ~/Library/Thunderbird/Profiles/profile.tar.gz.

Copy the name of the generated profile to the clipboard, and delete it.  Then rename the profile you copied from machine 1 to the name of the generated profile.
Launch Thunderbird, and you should be good to go!


Mac OS X does not have a feature like Windows System Restore Points. Doing this sort of thing on a Mac is considerably more involved and problematic.

That being said, there are other options and workarounds for troubleshooting your system's performance and how to fix it. I'll have to leave that for another post.

Have you been using Time Machine to make complete backups of your Mac to an external hard drive, every hour, every day?


Is it possible to downgrade an iPhone from iOS 8 to iOS 7?

Nope.

Apple has stopped 'signing' for iOS 7.

Unless some new 'method' is found, the change is irreversible.


Sending control+left command with external footswitch, delcom, only picking up control

oh boy, from kinesis [website][4]

  Note: Modifier actions from one USB device
  cannot modify the input of a second USB device due to limitations
  designed into the Apple operating system. Example: Shift, Control,
  Command, or Option keystrokes programmed into the footswitch cannot
  modify the input of a separate USB keyboard or mouse. However, a key
  sequence like ‘Cmd-W’ or ‘Cmd-Shift-left arrow’ will work on a
  Macintosh if the entire sequence of keystrokes has been pre-programmed
  into the footswitch. (Footswitch can only be programmed on a Windows
  PC).

I just tried this using my usb keyboard and built in osx keyboard and it seems to be true.  I can hit control + left on my usb keyboard and it works fine but control on my usb keyboard + left on the builtin keyboard does not work:(

Great news! Karbiner is a mature open source project that allows modifing across devices as a feature.
https://pqrs.org/osx/karabiner/document.html.en

  Share state of modifier keys with all connected keyboards: When you
  are using multiple keyboards, modifier keys are shared with all
  keyboards. For example, pressing "shift key on keyboard1" and "space
  key on keyboard2" sends shift-space.


Remove author metadata from PDF annotations in preview?

I have the exact same problem. While you should anonymize yourself in the prefs, I don't fully trust that method, so:

Make a copy of the annotated PDF file
Drag and drop to open in a text editor like TextWrangler, or hex editor like  HexEdit
(Don't worry about any binary-looking weird characters)
Search for your name and replace with the exact same number of Xs or I usually throw in a space among the Xs so it looks like a different name.
Save the file in place
Open in Preview and mouse over the annotations to see the anonymized version


Why such slow download of windows support software?

You can download the Boot Camp Support Software directly from here (554 MB).

A workaround with instructions and link to download can be found here:

The download file is a .zip file. Double click it to uncompress it,  if it is not automatically uncompressed.
Double-click the Boot Camp5 folder.
Copy the entire contents of the .zip file to the root level of a USB flash drive or hard drive that is formatted with the FAT file system.
When running Windows, locate the Boot Camp folder on the USB media you created in Step 3 and double click to open it.
Double click on setup to start installing the Boot Camp Support Software.
When prompted to allow changes, click on Yes and follow the onscreen instructions.
Installation can take a few minutes. Don't interrupt the installation process. When installation is complete, click Finish in the dialog that appears.
A system restart dialog box appears.  Click Yes to complete the installation.

For detailed information about Boot Camp, please visit this link.


AppleScript to Make New Calendar in Specific Account

You could use GUI scripting like this...

tell application "System Events"
    click menu item "iCloud" of menu 1 of menu item ¬
        "New Calendar " of menu 1 of menu bar item ¬
        "File" of menu bar 1 of application process "Calendar"
end tell

But one of the problems with this solution is you cannot set the properties of the calendar.  The new calendar will be named "Untitled"


How to prevent "Do you want to terminate running processes" window when shutting down?

Terminal Preferences → Profiles, select the profile you're using (probably marked Default) in the sidebar on the left, then choose Shell. Under ‘Ask before closing:’, choose Never.


Note: Join clips option in iMovie cannot be used for joining two different imported video clips. It can only be used to join clips created by splitting an imported clip in iMovie.

So, essentially if you have two clips which are to be combined, click on the Share icon in the Top right corner, then click on the option File and export all the clips as a single video file. You may then re-import it into the project if required after the share is successful.

For a quick 2 min demo, watch this: https://www.youtube.com/watch?v=8Px_I5fvJbk


MacBook Pro Mid 2015 Display flickering to static/weird colour during usage

This is a hardware issue; most likely a failed GPU.

I wrote an answer addressing this same issue but diagnosing by booting a Linux is not so easy anymore.

You can attempt to run Apple Diagnostics by booting and holding D.  It may or may not return an error code.

However, virtually every time I’ve seen something like this, it required a logic board replacement.


iPhone contacts off by one digit and/or swapped digits

I think it's most likely user error. I haven't heard of any bugs like this elsewhere, and it would be a particularly odd manifestation of data corruption. Keep an eye on it, but it probably just got incorrectly entered.


How can I remove remnant processes from deleted preference panes?

Many preference pane applications also have background processes or kernel extensions. Removing the preference pane doesn't remove them, so you have to run an uninstaller or delete the files separately.

Background processes are often started by launchd services in the LaunchDaemons or LaunchAgents folders. You can remove them by just deleting the property list files (and restarting or logging out and back in). Some applications add login items that can be removed in the Users & Groups preference pane.

The executables for the background processes are often somewhere in the root or user library, but they don't necessarily have to be removed.

Kernel extensions (in /System/Library/Extensions/) can also be removed by just moving them to the trash.

You can use Consultant's Canary to print a list of components that didn't come with OS X.


Can I still have several email addresses under one account?

If you have an old account you can still choose to enable to work with old domains like mac.com or me.com in the diffrence settings as for example Messages or FaceTime.

If you want to use your old mail addresses in Mail.app, you have to enable them in:

  https://www.icloud.com/#mail/prefs-addresses

New created icloud.com addresses can only be used with that domain, and don't have access any longer to the me.com or mac.com domains.

Hope that helped you!


If it is the same as mine, it was fixed by:

Opening Activity Monitor and see if any background processes are running.
If there are, then quit them.
If that didn't work, you might need to do a SMC. System Management Controller reset.

To reset the SMC:

Shut down the computer.

Plug in the MagSafe or USB-C power adapter to a power source and to your computer.

On the built-in keyboard, press the (left side) Shift-Control-Option keys and the power button at the same time.

Release all the keys and the power button at the same time.

Press the power button to turn on the computer.

On MagSafe power adapters, the LED might change states or temporarily turn off when you reset the SMC.

To read more about troubleshooting the fan read this: https://support.apple.com/en-ca/HT201295


Is it possible to connect 3 non-Apple monitors to a 2014 macbook pro retina without adding extra hardware

It doesn't matter if you have the 13 inch or the 15 inch model - Apple supports two external monitors. One HDMP or Thunderbolt. The other Thunderbolt.

You'll need extra hardware to connect more displays or even ones that don't connect to the ports on the hardware.

See footnote 4 in https://support.apple.com/en-us/HT204154

  MacBook Pro (Retina, Mid 2012), MacBook Pro (Retina, 13-inch, Late 2012), and Mac Mini (Late 2012 and later) computers can use an HDMI-compatible device on it's HDMI port while using one Thunderbolt display, or they can use two Thunderbolt displays.


Can I run an SQLite operation from Terminal?

Yes. You can use the /usr/bin/sqlite3 command line tool to modify the database. It ships, default, with OS X so you don't need to do anything other than open a Terminal window and then run:

cd path/to/quicken/storage/directory
sqlite3 <quicken database file>

SQLite version 3.7.13 2012-07-17 17:46:21
Enter ".help" for instructions
Enter SQL statements terminated with a ";"
sqlite> UPDATE ZFIPAYEE SET ZNAME = replace(ZNAME,'DEBIT PURCHASE - ','');
sqlite> .quit

You can do it all from one command line like this if you like:

sqlite3 <quicken database file> 'UPDATE ZFIPAYEE SET ZNAME = replace(ZNAME,\'DEBIT PURCHASE - \',\'\');'

That will open, modify and close your database file and return the prompt.

For more information on using the SQLite command line too see: http://www.sqlite.org/sqlite.html


migration assistant fails to move data files

I am sure you read the instructions how to migrate on Mavericks.

There is also the manual data transfer information here.


The Apple TV 2 has 110V/220V PSU or just 110V?

This US Apple Store webpage says that the current Apple TV (2) has:

  Power: Built-in 6-watt universal power supply

So yes, it looks like it will be fine in Europe.


Why can't I access all commands in recovery mode?

The recovery partition is a bare-bones version of macOS which can be used as for various things, such as installing macOS again or disable SIP (system integrity protection). To keep the recovery partition small, Apple decided to not include all CLI tools that are available in macOS.

For security reasons, not every user is able to access all files. The root user should be able to access all files and run all programs. It's a permission issue. However, he's not able to run programs that don't even exist on the recovery partition, so changing the user to root won't help you.

If you do want to use those programs, you shouldn't be using the recovery partition anyways but boot a standard macOS partition.


Open page in new tab without closing menu

Although I hesitate to assert that there is no analogous function in Chrome on OS X, I can’t find one built in.  However, there are some plugins that might help, such as the Mouse Gesture Extension and Shortcut Manager, although you will need to fiddle with these a bit to get the feature you want.  I hope this helps.


The netboot image loaded by booting to Internet Recovery Mode apparently doesn't contain the executable csrutil.

The OS X Base System loaded while booting to Recovery Mode should contain it though. By pressing cmdR a 2-step procedure is initiated: First the Mac is booted to Recovery HD and then after expanding BaseSystem.dmg to "OS X Base System" (which is the name of the mounted BaseSystem.dmg). If you see an animated globe after pressing cmdR your Mac probably doesn't have a Recovery HD.

Check the system version (or product version) of the Recovery HD/Base System:

To check the system version (1 in the screenshot below), boot to your main volume and enter the following in Terminal:

diskutil list #to get the disk identifier of your Recovery HD; usually it's disk0s3 with a size of ~650 MB
diskutil mount disk0s3
cat /Volumes/Recovery\ HD/com.apple.recovery.boot/SystemVersion.plist | grep -A 2 ProductVersion

Additionally you may mount BaseSystem.dmg and check the system version (2 in the screenshot below) there also:

open /Volumes/Recovery\ HD/com.apple.recovery.boot/BaseSystem.dmg
cat /Volumes/OS\ X\ Base\ System/System/Library/CoreServices/SystemVersion.plist | grep -A 2 ProductVersion

Download and reinstall the latest OS X El Capitan full installer if the system version of the base system is 10.10.x or lower.


How to organize/receive emails on one account while sending from another

If you want all email send from one account (i.e. gmail) you can set that up in Mail preferences.

Open Mail Preferences then select Composing:

Now select your gmail in the "send new messages from:"

Obviously in Mail you will need Yahoo and Gmail accounts.

Alternatively you can use the "Reply to" in Mail app.

For that Start a new mail and go View - "Reply to Address Field" or simply use shortcut alt+cmd+R. Then enter your reply to address. Now when you send new emails or you reply to emails it will use the selected email.

The third option: if you are really serious with that, you can use the Terminal app located in your Utility folder.

Type "defaults write com.apple.mail UserHeaders '{"Reply-To" = "reply-to@address"; }'" (excluding the outermost quotation marks) and replace reply-to@address with the address you want to be used for replies.

Read more here


X Lossless Decoder, Max. Both open source and for mac.


How to expand SD Card disk size (clone smaller SD Card into Larger one)

Try booting from a GParted Live USB stick. You should be able to resize the FAT partition with that utility.


Why ever does Parallels 8 recommend max 4 GB RAM for a VM?

It might be that the majority of the OSes that people virtualise (or at least those doing so with Parallels) can only use 4 GB of RAM anyway because they are 32-bit OSes, so it would not be necessary to have more than that. You shouldn't need more than 4 GB of RAM in the virtual machine anyway, so you partly answered your question. The majority of laptops these days don't have a massive 16 GB of RAM like you do; Parallels is only looking at the market side of things there.

If you really need more, why don't you just Boot Camp (you can Boot Camp with Linux as well); that way, you will use all of your computer's power if you need it. With your SSD, it won't take too long to restart.


You can enter Responsive Design Mode to set a custom size and resolution of the viewport.

Enable the Develop menu from Preferences → Advanced → Show Develop menu in Menu bar
Choose Develop → Enter Responsive Design Mode.


Yosemite Upgrade changed numeric keypad "Enter" key to issue "^[33OM"

Actually, I found the simplest answer...  In Terminal Preferrences, Advanced Tab, I unchecked the box in the 'Input' options section: "Allow VT100 application keypad mode"

Now the keypad ENTER key is identical to the main keyboard ENTER key!

Simple and sweet, I found this when looking through the TMUX help information.

I didn't realize that the only place where the keypad ENTER was issuing "\EOM" was in my tmux sessions, since that is the default mode in my remote admin sessions.  Thanks for the information above, but this was all I needed to do.  I've I'd given more background people may have had better clues.


Optimal method to test an external hard drive?

Apple's Disk Utility doesn't have false positives but it can miss some errors.

Although it's not cheap Disk Warrior is magic for these sort of problems, in my experience it's fixed all non-physical-damage errors that I could throw at it.

If you're not keen to spend money, and if you've got the hard disk space, copying the contents off, repartitioning your external drive and copying back on on might clear up your problems. Copying the whole disk's contents (starting with what is most valuable to you, in case it dies while you're copying) is probably a good idea anyway, in case your disk is on its death bed.


How to operate an iPad from a Mac or Windows PC?

You cannot wake an iPad with standard software from the desktop. You'll have to use one of the iPad models that support Tap to Wake instead (i.e. they can be woken up by touching the screen, and/or for some models by using the Apple Pencil on the screen).

For demoing the webpage you can use the Safari Web Inspector. On the iOS device you'll need to access System Settings => Safari => Advanced and then enable "Web Inspector".

Connect the iPad to your iMac and open Safari on the iMac. From the desktop Safari's Preferences, you'll need to enable "Show Develop menu in menu bar" in the Advanced tab.

Now you'll have a Develop menu in Safari where iPad has its own submenu. When you open Safari on the iPad, you can choose it from that menu - and you have various tools at your fingertips. For example you can highlight elements on the page using the element finder, or you can navigate to other pages, run Javascript code, or whatever you would like.

The above works because your use case is specifically to demo a web site. There's no generic solution for remotely controlling the iPad across the wake screen, home screen, built-in apps, third party, apps, etc. Solutions exists that allow you to see the contents of the screen (for example using Quicktime to record on the iMac, or using third party solutions such as TeamViewer). However, none of those allow you to remotely control the iPad.

It is possible to integrate remote control in specific apps, but it requires you to be able to modify the app - so it is in practice only an option for the app developer.


Just exchange the sim card with a "Bell network" sim card,

or go to settings->carrier->automatic->off->and select Bell


AppleScript to find a tab by its name in Google Chrome

Not being sure of the total scope of what you're trying to accomplish, the follow code may be more then you needed. However, it does allow for searching the Tab's Name and then sets the Tab containing the search string as the active tab.

The code below is a rework of the code presented in Find Safari Tabs with AppleScript. It would have been nice to have been able to change tell application "Safari" to tell application "Google Chrome" and the script worked, but because of the differences in the properties of a Tab between the two Apps, this is why that wouldn't work.

What this script does:

Displays a dialog box in which you type what to search for within the Names of the Tabs.
If the search string is matched in only one Tab, then that Tab is set to the active tab index, meaning that Tab is now the current tab. If there's more then one window, the window containing that Tab is brought to the front of all other Google Chrome windows.
If the search string makes multiple matches, then a list dialog is presented to choose from, then that Tab is set to the active tab index, meaning that Tab is now the current tab. If there's more then one window, the window containing that Tab is brought to the front of all other Google Chrome windows.
If the search string is not matched, a dialog box stating "No match was found!" is displayed.

set searchString to text returned of (display dialog "Enter a string to search for:" default answer "" with title "Find Google Chrome Tab")

tell application "Google Chrome"
    set win_List to every window
    set win_MatchList to {}
    set tab_MatchList to {}
    set tab_NameMatchList to {}
    repeat with win in win_List
        set tab_list to every tab of win
        repeat with t in tab_list
            if searchString is in (title of t as string) then
                set end of win_MatchList to win
                set end of tab_MatchList to t
                set end of tab_NameMatchList to (id of win as string) & ".  " & (title of t as string)
            end if
        end repeat
    end repeat
    if (count of tab_MatchList) is equal to 1 then
        set w to item 1 of win_MatchList
        set index of w to 1
        my setActiveTabIndex(t, searchString)
    else if (count of tab_MatchList) is equal to 0 then
        display dialog "No match was found!" buttons {"OK"} default button 1
    else
        set which_Tab to choose from list of tab_NameMatchList with prompt "The following Tabs matched, please select one:"
        if which_Tab is not equal to false then
            set oldDelims to (get AppleScript's text item delimiters)
            set AppleScript's text item delimiters to "."
            set tmp to text items of (which_Tab as string)
            set w to (item 1 of tmp) as integer
            set AppleScript's text item delimiters to oldDelims
            set index of window id w to 1
            my setActiveTabIndex(t, searchString)
        end if
    end if
end tell

on setActiveTabIndex(t, searchString)
    tell application "Google Chrome"
        set i to 0
        repeat with t in tabs of front window
            set i to i + 1
            if title of t contains searchString then
                set active tab index of front window to i
                return
            end if
        end repeat
    end tell
end setActiveTabIndex


None of my admin accounts are sudo users

It sounds like your employer has disabled using sudo commands from any admin account, instead opting to include only specific users. This would mean only the employer's admin account would be able to use sudo. If you no longer have access to this account, you could boot into Single User Mode and run the visudo command to fix it. If they didn't remove the user from the sudoers list, you could also make a new admin account with the same shortname.


To delete a video:

From Home Screen
Tap Settings
Tap General
Tap Storage and iCloud Usage
From Storage Tap Manage Storage
Tap TV app

You will now see your videos in the app and at this point you can hit Edit and delete the videos you no longer want.

Shorter option:
Or you can click into the video and you'll see a Downloaded button.  Click that and you'll see the option to remove the video.


I would like to suggest a little script that I wrote to solve this problem without hacking the system.

The idea is that the boot sound is not played if the Mac was muted before shutting it down. So this script basically mutes the Mac right before the shutdown and restore its previous state after login.

It should work on any version of OS X, and I tested it on my MacBooks with Yosemite.

You can find it on GitHub: https://github.com/teored90/nobootsound

The README tells you how to install the script. I hope this works for your system and I'd like to hear your feedback.


I think I have bricked my MacBook Pro, what are my options to get it fixed?

Take it to an Apple Store (make an appointment first): they'll examine and diagnose it for you with no charge, and then tell you what they'd charge to fix it.

Doesn't cost you anything and if the price is too great or you'd rather fix it yourself (now that you know the problem) then you can simply decline the service. It's a no-pressure deal, and one of the primary reasons I recommend Macs.


Is BetterTouchTool the recommended app to improve gestures?

I personally use it, and believe me it's awesome. I'll give it 4.5/5


In my book, Adobe Flash is always the first culprit for issues with browser stability and responsiveness. Try installing ClickToFlash and see if that helps things.


How to enable shortcuts through Siri on Apple Watch?

I just tried some of my shortcuts, and they work perfectly fine on my Apple Watch.

However according to Apple:

  Shortcuts that require an app to open on your iOS device might not
  work on HomePod and Apple Watch.
  (Source: Use Siri Shortcuts)

So maybe that is the reason your shortcut works on you iPhone, but not on your Apple Watch.


How can I backup a VirtualBox VM with TimeMachine

I have an answer, it's not the answer but it just recently saved my posterior when my iMac's HDD crashed a few weeks ago so I thought I would share.  It's not a short read, but I think it can help.

There are many issues around VM's that can cause headaches for backup strategies - size of the VDI files, snapshots, backup time, etc.  Consequently, I decided to chart my own path here to make things simplier.

I avoid the "putting all your eggs in one basket" strategy.  What this means is that while I have a VM running FreeBSD for web development, what get's developed is nowhere on the VM.  Here's a map of what my environment looks like:

The graphic needs to be updated because I no longer run Oracle Linux 7 as I have switched to FreeBSD 10-2.  I also have 4 USB drives attached to the Synology, not just one.  But those are minor and the concepts are still exactly the same.  Following is how I put it all together...

The Architecture

My environment consists of my

Synology NAS (RAID 1) with an iSCSI Target configured to hold all the data for the FreeBSD VM
a USB drive to backup that iSCSI LUN
a cron job on the Synology to take daily snapshots of the dev directory (this includes a daily MySQL dump)

On my iMac

a dynamically sized VDI that maxes out at 24GB
FreeBSD VM configured how I like, updated will all the latest patches and updates
FreeBSD VM "bridged" so it appears as a node on my network and not NAT'ed behind VirtualBox
iSCSI Initiator that connects to the Synology iSCSI LUN
the VM autoboot set to enabled so that it will automatically boot the VM across reboots
Time Machine configured to backup once per day

How This Works

Because I have an iSCSI target mapped to my FreeBSD VM, anything I do is changed on the Synology, not the VM itself.  As far as FreeBSD is concerned, it's just another mount point.  In this case, I created a mount point

/mnt/web/http/htdocs    -----> Synology iqn.diskstion.local-some-name

Why iSCSI?  iSCSI is block level, not file level.  As far as the OS can tell, you have attached another hard disk to your OS.  You format and partition it the same way you would any drive you added to your system.

I then changed the DocumentRoot in httpd.conf to the aforementioned directory.  Now, if you point  your browser to the web server being hosted on my iMac, all the files are coming from the Synology and just passing through the VM. If I write new code, it's on the Synology.

Oh...the MySQL data directory...you guessed it...on the Synology!

Backing Up

Once I created the FreeBSD VM the way I liked it, I immediately archived a copy and put it on the Synology and on a USB stick.  It was only 4GB, by the way.

I tested out the restore procedure by deleting the VM on my iMac and then copying it back to my iMac's VM directory.  The trick is, instead of Importing/Exporting, you just "Add" it to VirtualBox and "Open" the .vbox file of the machine you copied over.

Now, my FreeBSD image was only 4GB and it never changes - unless of course I do an update.  So, there isn't a need to back this up with Time Machine (unless I want to) because it only changes when I do an OS update.

The Synology is configured with a RAID 1, so the disks are mirrored.  If one fails, then I still have the other; that my first level of data protection.  I also have a daily backup going to a USB drive;  that's my second level.  I also do a daily directory snapshot using tar and mysqldump that's cron'd (on the Synology); third level.  Synology has the ability to sync to cloud providers so in effect, if I set this up, there is now 4 levels of data protection available to me.  Buy another NAS and use rsync...5 levels...and so on....

How this Worked

So earlier I said that this saved my bacon when my HDD crashed.  Because my data existed on another drive, it was safe.  I had my VM image backed up in two places so that was at the ready.

When I copied my VM back to my new iMac, once I loaded it up, it knew where the iSCSI target was and immediately went to work.  I restored in less than 10 minutes total and that's including the time to find and copy the VM master image over to my new iMac.

But that's not where it saved my bacon...

I chose to upgrade to a 1TB SSD and delivery would take 2 days.  I couldn't be down for two days, so I copied the VM to my Surface Pro 3, loaded it up, and because  the VM "knew" where the Synology iSCSI target was, I was back up in business in 10 mins  on a completely different computer.

You don't need an external NAS

Ok, so maybe my setup is a bit overkill with an NAS and iSCSI.  However, there is nothing to prevent you from setting up a "shared directory" on your Mac and sharing it via NFS and mounting it on your VM. Remember, the VM is setup to be it's own node on the network; it has no idea that it's looping back to the shared drive where it's getting it's data from. With this setup you can still get the benefit of the VM never changing and only backing up what has changed which would be what's in the directory being shared via NFS.

Conclusion

I have always subscribed to the philosophy that data protection is not a product or service you buy; it's a strategy you employ.  I found that relying on one thing (i.e. Time Machine) is a disaster waiting to happen.  By building this as levels of protection I can be very efficient as well as highly backed up incase of disaster.  It also allows me to be extremely flexible and "rapid" in coming back online.


Can I delete any of these items from library?

Okay, apparently this is normal. Saw a discussion stating that the 15GB volume secured files from malware according to this discussion on an apple thread. So I guess it has to stay. https://discussions.apple.com/thread/252032330


Trackpad secondary click requires more pressure than usual in Mojave beta

Not sure if this would solve the issue but you could try and pass by the Apple store or certified repair center and see if they could help you recalibrate the trackpad.

Service centers have tools to calibrate trackpads. I've been an Apple Certified Mac Technician for 6 years and we do this every time a machine has been opened.


IOS messages - contacts with both IOS and text messaging

So long as your children have iMessage turned on Settings.app > Messages > Turn iMessage *on*, you can determine which device you are messaging based on the color of your message bubble backgrounds or, in your specific example, the "Send" button color (while typing):

Green = non-iOS dumb phones.

Blue = iOS devices.


Which animations will work on Keynote export to PowerPoint?

Check this page out: https://blog.udemy.com/keynote-to-powerpoint/ Hope this helps!


You can temporarily display the protocol by activating the address bar with ⌘ Cmd-L and copy-pasting the current URL back to the address bar with ⌘ Cmd-C, ⌘ Cmd-V.

The protocol will, however, disappear again as soon as you load a new page by following a link on the page or pressing Enter in the address bar.


What is the root username and password for CUPS 2.1.0

Normally you don't need to enter a root username and password to use CUPS. The error is likely to be in /etc/cups/printers.conf You could check the authorization entries in your printers.conf

Even simpler though is that CUPS.org recommends just using your normal admin username and password when asked for authorization:

  Use the username and password for your computer.

You will need an account with admin privileges: most OS X computer owners have such an account, it's usually only in an lab or a company where you wouldn't have admin privileges.

I hope this works in your case, Esmeralda. If it doesn't please post some follow up information, such as your printers.conf file.


Why did Apple assign the wrong name to my AppleID, and how do I change it?

If the name on the Apple ID or the billing address is incorrect, you can fix it at https://appleid.apple.com

You can edit the name on the account here...

And you can edit the billing name here...

(Look for the Edit buttons.)


File has different owner if examined using `sudo`

These files are owned by UID 99, which is the unknown user.  These files were, perhaps, initially created by an account that is no longer on the system, or a "different version of yourself" that was migrated from a previous version of the OS, etc.  To avoid confusion, when a normal user inspects these files, they appear to belong to whoever is viewing them.  When root inspects them (via sudo, for example), their actual owner is shown.

The following describes this in greater detail:

http://googlemac.blogspot.com/2007/03/user-99-unknown.html


How can I view all Wi-Fi network names (SSIDs) in my area?

There is a program you can run in terminal.
/System/Library/PrivateFrameworks/Apple80211.framework/Versions/Current/Resources/airport -s

Update for 2021:  This command still works (as written) in OS 11 Big Sur.


How to drag files into an app's Dock icon in macOS Sierra?

I have just upgraded to Sierra and I am experiencing exactly the same problem, and not only with Outlook.
I hope this bug will be fixed in the next release of Sierra.

In the meantime, immediately after beggining dragging I press F9 to show Mission Control and select the target window.
Most times, this works.


MacBook Pro only turns on at specific times after cleaning

Has a schedule been set up? Check in Preferences > Energy Saver. Look at the bottom right under Schedule. You didn't do the cleaning with the power on? Did you hit a shortcut key combo? Here is a shortcut discussion with some common ones to check.: https://support.apple.com/en-us/HT201236


You have many ways to do this, but the easiest or simplest way to do this would be to mirror your whole display to the apple TV using the icon in your status bar, if you already have air play mirroring set up. If you don't have it set up go to system preferences > display and there should be an option in your lower left-hand corner. Unlike in iOS, airplay isn't really targeted towards specific apps. I don't really know about the Bose thing, but if you're referring to a sound system, as long as it's hooked up to your TV you should be fine. If you mirror and the sound still plays from your computer try changing the output in system preferences > sound


How to selectively force Siri to send iMessage instead of SMS?

I believe that the siri command for imessage is: Message Alice i'll be there soon. This will not prevent it from sending a text message. To prevent it from sending a text message, go into settings --> messages --> and turn off the "Send as SMS" switch.

In her contact it should look like this:

Alice Appleseed

Phone: (XXX) XXX-XXXX

Email: aliceappleseed@xxxxxxx.net

What you need to do is try to message her on one of these accounts.

Try saying: "message alice on her email...I'll see you later"

Then: "message alice on her mobile...I'll see you later"

The point is: you want to state where you want to send the message. If you just say "message Alice", then siri will ask you where you want the message to go.

Since the iPad doesn't have a phone number, you message it through its email address (this will have to send an iMessage). The non-iPhone uses its phone number (this will have to send a text message).

I hope this helps.

Update: Brought to my attention by the author of the original question, the method above: "message alice on her email...I'll see you later" is not fully effective.

Rather, saying it this way:

  "message alice on iCloud...I'll see you later"

will send the imessage to Alice's iCloud email address (which must be set up by her as an E-mail address which can contact her via imessage). Note: If I'm correct, the E-mail account used as a contact point does not have to be an iCloud account (although it may be better to use one anyway). For instance, you could use the E-mail account of johnny.appleseed@example.com, yet label it as an iCloud account in Contacts, and it SHOULD work the same.

Sadly, I have since stopped using Siri, simply because I have been too busy, so feel free to correct me if I am wrong about this all.

Glad I could help. (surprised that you remembered my answer, since it was written a good while ago.)


Prevent & disable iPhone iOS 9.2 from forced/ pushed auto downloading updates?

The closest I came was preventing all my iOS devices from reaching the update server. This envolves configuring your internet router in order to do so.

Configure your router to block the following domain: mesu.apple.com

Doing so will still allow your iDevice to talk to the Apple Store, allowing you to download/update iOS Apps.

Some routers (like mine) only allow me to block 'web sites' not domains. Luckily, that is all we need to do. Blocking https://mesu.apple.com also does the trick.

I would say blocking the whole domain is a cleaner solution if possible however.


Can the iPad support multiple Regional Settings simultaneously?

You can have multiple keyboards enabled: Settings -> General -> Keyboard -> International Keyboards. Add whichever keyboards you wish. Then, when you are typing text, hit the globe key on the keyboard to switch between the different keyboards.

As far as I know, you can't have multiple languages enabled at the same time for spell checking. However, you can switch between them using Settings -> International -> Language.


No commands installed from pip work in Terminal

I would comment, but I don't have enough coinage.  We need to figure out what is wrong:

The packages do not exist in a known path that you have.  We know this.  So what is causing it?  Either it's not being installed, or it is being installed and the binary is not in PATH.

First, make sure it is being installed properly by pip.  Do a pip install and let us know the output.  Also let us know the output of pip list after the install.  I just went to console, switched to a virtual environment, then did a pip install on restview.  It installed successfully in virtual_env_path/bin/ and also my pip is located in virtual_env_path/bin/

So, if it is installing correctly I would find out where pip is located by typing which pip

Then see if the packages you are looking for are in that path, or near there.  Clearly, that directory is in your path since pip runs.  If you find the packages, make sure that directory is added to the path if they are not.  Remember PATH resets each time you open a new console.  Check path via echo $PATH

Basically, if it is installed, you must find out where, then compare that to your path.  Good luck.


Can I change the color of the menubar in 10.9 Mavericks?

You can change the colour of the menu bar to black with Obsidian Menu Bar, but this doesn't change the text colour:

  Obsidian Menu Bar

  A hack that makes your OS X menu bar black. And yes, it blends.
  Ready for 10.9.2!


Why is an AppleScript to modify Calendar event attributes so slow?

Use CalendarLib. CalendarLib is a Script Library that lets you work with Calendar events without using the Calendar app. It is very, very fast:

  CalendarLib

  CalendarLib is an AppleScript script library for manipulating calendar events without using Calendar.app. It requires OS X 10.9 or later, as well as the BridgePlus script library.

I do not know why Calendar is so slow with AppleScript.


How to paste information from JSON Helper

You can use the set the clipboard to command.

tell application "JSON Helper"
    set myRecord to fetch JSON from "http://www.nfl.com/liveupdate/scores/scores.json"
    set the clipboard to (make JSON from myRecord)
end tell


How do I fresh install on used OSX 10.6.8?

The Recovery HD (which is what holding down Option would enable you to access) didn't come into being until Lion. You should go to the App Store, sign out of the previous owner's Apple ID, sign in with your own, download and install Yosemite, and then you'll have the Recovery partition from which you can do a wipe/fresh install.


See a log of all DMG files that were mounted

This is normal and you need not worry about it.

When certain system items are updated, a recovery partition is mounted to update the boot (or other) configuration.  It is then un-mounted, all without showing a icon for the drive on the desktop.

You can see the recovery partition by issuing diskutil list in a terminal window.

You should see something like:

/dev/disk0
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                        *1.0 TB     disk0
   1:                        EFI EFI                     209.7 MB   disk0s1
   2:                  Apple_HFS HARDDRIVE               499.7 GB   disk0s2
   3:                 Apple_Boot Recovery HD             650.0 MB   disk0s3

The Recovery HD is the one that is mounted.


Override wallpaper with VMware AirWatch Agent

In general, the success rate of overriding MDM enforced configuration changes is very low. Pragmatically:

You can remove the management profile and then make changes as you see fit.
You can request your device be moved to a different group under air watch that relaxes that restriction.

There could be a bug you could exploit, but Apple and/or air watch would likely patch that since it would also likely be a noticeable failure.


Restore files after changing disk format from NTFS to HFS+

No. You're data is well and truly gone. The reformat will have removed all the file tables so that while the data may well be on the drive blocks there is no way of knowing what block belongs to what file, what the files were called and what the directory tree might look like.

Sorry for the bad news.


There are a few apps out there that claim to be able to do this. iLock (http://www.osxbytes.com/ilock.html) and Mac App Blocker (http://knewsense.com/macappblocker) are two, though not free.

Creating a non-admin account as Patrix suggested, and only using that during the party is the best solution since party-goers won't be able to see anything of yours (mail, browser history, files, etc). You'd just need to share your music with that non-admin account (this describes the process: http://www.cnet.com/how-to/how-to-share-itunes-libraries-between-user-accounts-in-os-x/).

If you want to use your account, the most effective way would be to turn on Parental Controls in your Settings, and only enable iTunes and maybe a browser. However this won't work if your account is an administrator account.

If your account is an admin account, and you want a free method of preventing someone from seeing your mail (I assuming you're using the OS X Mail app), you could rename your mail folder temporarily (Library/Mail) and then change your email password temporarily so that if someone opens the Mail app, they'll see nothing and it won't download any new mail. If you're paranoid, you could move the mail folder to an encrypted volume (created in Disk Utility) or a removable drive. But if you're that worried, using a different account for the party is easier and safer.


Can I retrieve my activation and deactivation history?

No, no actual history or log of either activation of deactivation exists.

Apple, though, sends to your iCloud account an email whenever your device gets the Find My Phone feature deactivated.


Ethernet-over-usb not working with usb-c to usb-c cable, working with adapter

I think the problem is that your USB-C to USB-C cable is in fact power only.
The setup you have should work when you connect it directly, but you write the USB part of System Report gives no indication that anything at all is plugged in. If you have used a charger cable that has no data lines, this is what would happen.
Try with a different USB-C to USB-C cable and it should hopefully work.
UPDATE: Based on your comments, the problem seems to be that the device itself doesn't actually support USB-C fully. You'll need to configure the Linux kernel with the CONFIG_TYPEC option in make menuconfig in order to have support for USB-C build.


Mac OS High Sierra how to see Username for the failed login attempt

After reaching out to Apple and not getting the answer, I was finally able to find the answer to this. To see the redacted information i.e. one that is marked as '< private >' I needed to turn on private mode. Here is the command to do that:

sudo log config --mode "private_data:on"

Now you can lock your screen and log back in and from now on the logs will show all the information that was earlier redacted and marked ''.

Hope this helps someone else looking for the answer.


Your iMac can only support TDM using thunderbolt connections, and as such can not be connected to your laptop.
You can learn more about TDM in this article


Yes, and iMovie can even delete (all) of them for you.

Go to iMovie > Preferences and click "Delete" next to Render Files (last item on the bottom for me).

It will warn you about deleting data, and that it may have to be regenerated in the future.

Inspecting my iMovie library with Finder after this operation revealed that it cleared the Render Files directory and freed up ~60GB from my disk.


Differentiate two instances of the same application in the dock

This is a solution for your particular issue, and not OSX apps in general on which I believe do not have this issue.

Workspace identifiers for Eclipse on OSX


Half of my iMovie videos disappeared, can I retrieve them?

I'm not sure how you filmed yourself doing the painting, maybe with an iPhone?  If so that's where I'd look.  Maybe you mean a digital painting and you were doing a screencast?  It's important to describe which hardware/software you used as it will determine the location of the files.  iMovie, I believe, you could have only used for editing.

As an aside, I can recommend using the Procreate iPad app for recording artwork, the feature is built in, you don't have to do anything to record as it happens automatically, and the resulting screencasts are very high quality and with good timing.


In the iTunes app on the phone, there is a "Purchased" tab. In there, you should be able to see everything that you have previously purchased, and download them anew.


Which built-in tools do Little Snitch-like applications rely on?

Little Snitch uses a network kernel extension to intercept network traffic.

  NKEs allow you to create modules that can be loaded and unloaded dynamically at specific positions in the network hierarchy. These modules can monitor and modify network traffic, and can receive notification of asynchronous events from the driver layer, such as interface status changes.

  Each of the networking KPI mechanisms performs a specific task. The basic networking KPI mechanisms are:

  Socket filter KPI, which permits a KEXT to filter inbound or outbound traffic on a given socket, depending on how they are attached. Socket filters can also filter out-of-band communication such as calls to setsockopt or bind. The resulting filters lie between the socket layer and the protocol.
  …
  Interface filter KPI, which allows a KEXT to add a filter to a specific network interface. These interface filters (previously known as data link NKEs) can passively observe traffic (regardless of packet type) as it flows into and out of the system. They can also modify the traffic (for example, encrypting or performing address translation). They essentially act as filters between a protocol stack and a device.
  …

Alternatives to network kernel extensions exist as you mentioned, but only for certain use cases.

  Because even minor bugs in kernel-level code can cause serious consequences, including application instability, data corruption, and even kernel panics, the techniques described in this document should be used only if no other mechanism already exists. For example, where possible, IP filtering should generally be done using ipfw. Similarly, packet logging should generally be done using bpf.

Network kernel extensions are far more powerful and allow for more detailed control.

Network Kernel Extensions Overview
Introduction to Network Kernel Extensions Programming Guide

Emphasis in quoted content mine. I am unfamiliar with the other software but I assume it follows the same principal.


The UUID is not the same as the serial number.

When you use any Mac, some machine-specific preference files are created in your Library/Preferences/ByHost/ directory.  The filenames are of the form

com.apple.app.UUID.plist

So, if you really want the UUID of a previously used machine, you can probably dig it up from some backups in that way.  I don't know how useful that would be though.

I think TimeMachine stores UUIDs of the filesystem, but not the computer itself.  Checking the logs on one of our servers here, I see several fsUUID and eventDBUUID but nothing for the machine.


Skype doesn't come in Hungarian (see the info published on the app store page for it). So it probably takes the next priority on your OS.  Is Chinese second on your Language list? If so, move English to the top temporarily so that it becomes the default after Hungarian.


You can do this with TinyUmbrella. Launch TinyUmbrella, connect your iPhone and give it some time until it's recognized by TinyUmbrella. Then click the “Exit Recovery” button.


spinning circle next to wifi symbol when music folder open

See the answer to What does the spinning circle next to the network indicators on iOS mean?

  Apps can turn on and off the indicator at will, so it's not a 100%
  reliable indicator that data is actually being transferred.

You could make an experiment: leave the phone idle for two hours and check how much energy is consumed with the app on and off, respectively.


Is /etc/resolv.conf changed every time my DHCP lease changes?

You could write a launchd that monitors the file path of:

/private/var/db/dhcpclient/leases/

If you looking for DHCP changes to an interface.

That db holds all the different interfaces and dhcp changes on them.  Something similar to monitoring that file with a launchd here.


Pool Multiple Hard Drives in ONE Network Share

There are two ways to do this. I've my combining both solutions I've found that I've been able to maximize both resiliency and flexibility.
1 - Server Side.
Use OSXFuse (https://osxfuse.github.io/) and  mhddfs, the latter of which you can install via MacPorts, to create a large drive pool. Then share that. (A wrinkle here here is that mhddfs runs in user space, typically after login, so file-sharing may need to be restarted after mhddfs fires. I'm still trying to work out that kink. If you figure anything out, please do share.)
Know that you can then also share the drives independently. Use the DrivePool share for reading, and the individual shares for writing (so that you have more control over where the files go).
2 - Client Side.
Use auto_mounter and mount all the drives individually on the client, but in the same folder. Although they are individually mounted, auto_mounter is smart enough that after a short sping-up-and-connect delay they basically act as a large, laggy folder on the client machine. This solution is suprisingly robust.
The settings will be a combination of two client-side manifest files, (1) /ect/auto_master, and (2) conventionally at /etc/auto_resources. The best tutorial for this is here - http://useyourloaf.com/blog/2011/01/24/using-the-mac-os-x-automounter.html. It's old, but the instructions still work perfectly on my machine using 10.9.5 on the client and server.
3 - Combine both solutions!
I have my mhddfs master drive pool on my client at /mnt/DrivePool, and the individual drives at /mnt/IndividualDrives/D01 through /mnt/IndividualDrives/D10. It looks a little clunky at first, but it is actually quite robust and flexible for my needs.


Is it possible to use iPhone's hardware vibrate button to toggle "silent" / "vibrate only" instead?

You could set your phone up to vibrate on silent and then configure your sounds to be short silent ringtones. Then when your phone is in "normal" mode it will play the silent alerts (The Sounds of silence... Yeah shouldn't try singing) instead of ringing.

Unfortunately you'd have to set multiple alert sounds (SMS/iMessage, Ringer, etc.) but here's a link to a step by step plus sample ringtones: http://www.iphonefaq.org/archives/971156


The term "freezing" here should not be interpreted literally. Freezing simply means that the display stops updating, audio stops playing or similar (i.e. nothing is happening) - it doesn't have anything to do with hot or cold environments.
The behavior you're seeing sounds like a hardware defect.
You mentioned already having tried upgrading iOS. I would take a backup of the phone, and then do a complete restore of the iOS software - erasing all contents and settings on the phone. If it still freezes afterwards, it is most probably a hardware problem.


Determine and Use Resolution as a Variable in UNIX script on Mac

If you are looking for something to put into a shell script, you can run something like

if [[ $(system_profiler SPDisplaysDataType |
             grep Resolution |
             head -1 |
             tr -d ' ') == 'Resolution:2560x1440' ]]; then
    # do whatever is needed to do for 2560x1440
end if

You could also use a case statement to handle several resolutions

case  $(system_profiler SPDisplaysDataType |
            grep Resolution |
            head -1 |
            tr -d ' ') in
    Resolution:2560x1440)
        # handle 2560x1440
        ...
        ;;
    Resolution:1920x1200)
        # handle 1920x1200
        ...
        ;;
esac


I like to go to the apple.com page where you buy a phone and tap the OS section. At the bottom of it, there is a small print section making note that not all features are available everywhere. Currently this link is:

https://www.apple.com/ios/feature-availability/

Sadly for you and residents of Myanmar - there is not one feature offered in that country. You may have to use your presence in another country to establish an account to use some of the features of the stores and OS that are only available in certain countries.

Start with the list above and perhaps pick one or two things you really need to do and see if you have any ties to those places to have some legitimacy for establishing an account without fabricating all the details or going to the expense of establishing an address in the US.


Apple Treats Transparent Images as a Black Background

Simply put, iOS uses the JPEG format when saving images to the Camera Roll, and JPEG does not have an alpha channel for transparency. When converting a PNG image to JPEG, all transparency data is lost. What is happening is the color 0x00000000 (RGBA - four octets) is being changed to 0x000000 (RGB - three octets).


My Fusion Drive Partitioning Seems Wrong/Strange/Wonky

This procedure is going to get you back to a "factory fresh" system where your 128GB SSD and 3TB (spinning) HDD are configured as a Fusion Drive.  Basically, we're going to:

Delete all partitions off all the physical drives
Create the Fusion Drive
Install macOS

Before you begin, ensure that you have

all necessary backups.
a bootable USB installer
WiFi and a working Internet connection (if you want to use Internet Recovery)

Erase the Disks
Using a bootable USB macOS installer, boot up then go into Terminal and issue the following commands:
$ diskutil partitionDisk disk0 1 GPT HFS+ MacSSD 100%

$ diskutil partitionDisk disk1 1 GPT HFS+ MacHDD 100%

Verify that the disks are wiped clean by issuing the command
$ diskutil list

You should see two disks with a single partition each.
Create the Fusion Drive
Create the Logical Volume Group
Next create a logical volume group by "combining" the two drives with the following command
$ diskutil coreStorage create <LogicalVolumeGroupName> /dev/disk1 /dev/disk2

You can use any descriptive name for the group.  Ex:  iMacLVG
When the process has finished, it will output some status information including the logical volume group UUID like below:
Core Storage LVG UUID: XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXXX

Copy that number to your clipboard.  You will need it for the next command.
Create the Logical Volume
Issue the command
$ diskutil coreStorage createVolume lvgUUID type name size

Where...

lvgUUID = the UUID you copied from the last step
type = the format you want to you.
name = the name of the Volume.
size = how big you want to make the volume.  Valid entries are in bytes (Kilo, Mega, Giga, Tera, Peta, etc.) and percentage (%)

So, to make a volume that spans the whole logical volume in HFS+ use the following example:
 $ diskutil coreStorage createVolume  XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXXX HFS+ "iMac HD" 100%

Once it's done, you've got a clean volume on which to install macOS.  Issue the command to verify that you've got 3 disks:  2 physical and 1 logical.
Install macOS
Exit Terminal and complete the macOS installation.  Restore your data by using the Data Migration Tool if necessary.


Removing configuration profiles via command line

The profiles command gives you command line access to change profiles.
To remove a profile, use
sudo profiles -R -p identifier
To get the identifier of a profile if you don't have it already, find it in the list of profiles given by
sudo profiles -P

You can't mess around in /private/var/db/ConfigurationProfiles, only macOS itself can manage files in there.


iMessage "Not Delivered" on my Macbook Pro Mid 2012

What you are trying to do is send SMS messages from Messages on your Mac to people without iOS devices, correct?  (Just fixed this for my wife this morning.)

Be sure to add your Mac to your iPhone's Text Message Forwarding.

On your iPhone:

Go to Settings
Messages then select Text Message Forwarding
There you will see a list of devices that use your Apple ID for Messages
Add your MacBook if listed.
Enter the code displayed on your Mac into the iPhone dialog when prompted.

Now you should be able to text from your Mac using Messages.

Apple support documentation for further reading.


Your Genius was misinformed. When graphical artifacts or distortions show up in a screenshot, they are a product of the graphics card. It is one of the quickest tests, we did it all the time to classify graphics issues. Most geniuses know this, like I said you got someone who was either new or off their game that day.

Long story short, you're absolutely right that it's the GPU.


I'm quite pleased with Pinboard. There are a number of browser extensions and apps that work with the API.


How to use Apple TV without a working remote?

Download the Remote app for iOS onto a device with BTLE
Connect the Apple TV to iTunes and restore it (you will lose everything that's currently on the Apple TV)
Use the iOS physical tap method to set up the AppleTV and pair it to your iOS device
Profit in not having to order a replacement battery or replacement Apple infrared remote or borrow one to get it set up again.

Note, once you have the iOS app paired, you can train AppleTV to respond to buttons on third-party infrared remotes so you don't need Apple's remote going forward.


How to Break up a Long Element List into multiple lines of code (Applescript)

If you want it more readable, then use property and separate the list you have into individual properties, e.g.:

property target : "Safari"
property slideNo : 2
property propsUrl : "https://docs.google.com/presentation/d/slideId/preview"
property rewardsUrl : "https://docs.google.com/presentation/d/slideId/preview"
property coords : {posX:937, posY:497, sizeX:149, sizeY:262}


The easy way to measure latency is with video and even iPhone 11 can capture 240 frames per second, so you’ll be within 5ms of measurement error.

https://danluu.com/input-lag/

If you have noticeable lag, it’s going to be likely you can use activity monitor to see what is slowing the processor or perhaps detect you have an issue on the USB bus resetting if there’s no obvious reason why keys are buffering and not going directly to the screen.


Is it possible to show custom icons in the Scripts menu?

I don't think it's possible, but FastScripts does seem to use custom icons in the menu:


I found the offenders in my case (plural, for several apps were using this plugin), using a ps -axe | grep FinderSyncExt .

Before removing the apps using it from my /Applications folder, I decided to kill each of the processes using a killall -9 FinderSyncExt.