Tuesday, April 6, 2021

Recent Questions - Ask Different

Recent Questions - Ask Different


Installing cocoapods to macOS Catalina

Posted: 05 Apr 2021 11:31 PM PDT

In my mac mini I've running Catalina 10.15.7. I've also installed Xcode 12.4. Now as I'm using third party library I'm trying to install cocoapods in my mac. So I used this -

sudo gem install cocoapods  

which I got from official website.

But I'm getting this -

Password:  Fetching concurrent-ruby-1.1.8.gem  Fetching fuzzy_match-2.0.4.gem  Fetching i18n-1.8.10.gem  Fetching thread_safe-0.3.6.gem  Fetching tzinfo-1.2.9.gem  Fetching activesupport-5.2.5.gem  Fetching nap-1.1.0.gem  Fetching httpclient-2.8.3.gem  Fetching algoliasearch-1.27.5.gem  Fetching ffi-1.15.0.gem  Fetching ethon-0.12.0.gem  Fetching typhoeus-1.4.0.gem  Fetching netrc-0.11.0.gem  Fetching public_suffix-4.0.6.gem  Fetching addressable-2.7.0.gem  Fetching cocoapods-core-1.10.1.gem  Fetching claide-1.0.3.gem  Fetching cocoapods-deintegrate-1.0.4.gem  Fetching cocoapods-downloader-1.4.0.gem  Fetching cocoapods-plugins-1.0.0.gem  Fetching cocoapods-search-1.0.0.gem  Fetching cocoapods-trunk-1.5.0.gem  Fetching cocoapods-try-1.2.0.gem  Fetching molinillo-0.6.6.gem  Fetching atomos-0.1.3.gem  Fetching colored2-3.1.2.gem  Fetching nanaimo-0.3.0.gem  Fetching xcodeproj-1.19.0.gem  Fetching escape-0.0.4.gem  Fetching fourflusher-2.3.1.gem  Fetching gh_inspector-1.1.3.gem  Fetching ruby-macho-1.4.0.gem  Fetching cocoapods-1.10.1.gem  Successfully installed concurrent-ruby-1.1.8  Successfully installed i18n-1.8.10  Successfully installed thread_safe-0.3.6  Successfully installed tzinfo-1.2.9  Successfully installed activesupport-5.2.5  Successfully installed nap-1.1.0  Successfully installed fuzzy_match-2.0.4  Successfully installed httpclient-2.8.3  A new major version is available for Algolia! Please now use the https://rubygems.org/gems/algolia gem to get the latest features.  Successfully installed algoliasearch-1.27.5  Building native extensions. This could take a while...  ERROR:  Error installing cocoapods:           ERROR: Failed to build gem native extension.    current directory: /Library/Ruby/Gems/2.6.0/gems/ffi-1.15.0/ext/ffi_c/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/bin/ruby -I/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0 -r ./siteconf20210406-1384-1vtmk4p.rb extconf.rb  checking for ffi.h... *** extconf.rb failed ***  Could not create Makefile due to some reason, probably lack of necessary libraries and/or headers.  Check the mkmf.log file for more details.  You may need configuration options.    Provided configuration options:      --with-opt-dir      --without-opt-dir      --with-opt-include      --without-opt-include=${opt-dir}/include      --with-opt-lib      --without-opt-lib=${opt-dir}/lib      --with-make-prog      --without-make-prog      --srcdir=.      --curdir      --ruby=/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/bin/$(RUBY_BASE_NAME)      --with-ffi_c-dir      --without-ffi_c-dir      --with-ffi_c-include      --without-ffi_c-include=${ffi_c-dir}/include      --with-ffi_c-lib      --without-ffi_c-lib=${ffi_c-dir}/lib      --enable-system-libffi      --disable-system-libffi      --with-libffi-config      --without-libffi-config      --with-pkg-config      --without-pkg-config  /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/mkmf.rb:467:in `try_do': The compiler failed to generate an executable file. (RuntimeError)  You have to install development tools first.      from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/mkmf.rb:585:in `block in try_compile'      from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/mkmf.rb:534:in `with_werror'      from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/mkmf.rb:585:in `try_compile'      from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/mkmf.rb:1109:in `block in have_header'      from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/mkmf.rb:959:in `block in checking_for'      from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/mkmf.rb:361:in `block (2 levels) in postpone'      from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/mkmf.rb:331:in `open'      from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/mkmf.rb:361:in `block in postpone'      from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/mkmf.rb:331:in `open'      from   /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/mkmf.rb:357:in `postpone'      from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/mkmf.rb:958:in `checking_for'      from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/mkmf.rb:1108:in `have_header'  from extconf.rb:10:in `system_libffi_usable?'  from extconf.rb:42:in `<main>'    To see why this extension failed to compile, please check the mkmf.log which can be found here:    /Library/Ruby/Gems/2.6.0/extensions/universal-darwin-19/2.6.0/ffi-1.15.0/mkmf.log    extconf failed, exit code 1    Gem files will remain installed in /Library/Ruby/Gems/2.6.0/gems/ffi-1.15.0 for inspection.  Results logged to /Library/Ruby/Gems/2.6.0/extensions/universal-darwin-19/2.6.0/ffi-1.15.0/gem_make.out  

I've seen this question but my ruby version is -

ruby 2.6.3p62 (2019-04-16 revision 67580) [universal.x86_64-darwin19]  

I've also take a look in this but could not able to solve the problem.

Edit:
I've used this -

xcode-select --install  

but got - xcode-select: error: command line tools are already installed, use "Software Update" to install updates

So, Is there any ruby dependency I've to install first or I just missed something?

How do you trigger search in iPad OS from anywhere without an external keyboard?

Posted: 05 Apr 2021 10:21 PM PDT

I know this is possible because I keep accidentally bringing up Spotlight Search randomly when I'm using apps. Not on the Home Screen.

I've searched and all I can find is that you can trigger the search either from the Home Screen, with an external keyboard, or with a11y controls and that there's no other way.

If there's a gesture for this I'd love to know what it is because I would actually use that. iPad Pro (12.9-inch) (3rd generation) iPadOS 14.4.2

  • I've never used an external keyboard
  • I use the Apple Folio Case
  • I use an Apple Pencil
  • I've been having issues with phantom touches near the corner of the volume keys side and USB port side
  • It usually happens somehow when, in landscape, my hand is near the top left of the screen but I can't reproduce it afterwards

Macports and Xcode

Posted: 05 Apr 2021 11:53 PM PDT

help I have no idea what I'm doing. I wanted a photo editing software on my MacBook Pro running big sir. I came across gimp and it suggested I install it using macports. I ran the macports installer without knowing I was supposed to install Xcode first and now I don't know what that would have done to my computer since as far as I know I don't have Xcode. I want a do over. How do I find and remove whatever the macports installer would have put on my customer?

2017 iMac crashes when booted from thunderbolt SSD

Posted: 05 Apr 2021 05:28 PM PDT

My dad's 2017 iMac with the 5400-rpm internal hard drive was painfully slow, so I installed Big Sur on an external 1TB Thunderbolt SSD and migrated the contents of the internal drive onto it. I am able to boot from the SSD normally, and it is fast and usable again - but only for a few minutes. Eventually, MacOS will crash, even without doing anything as a user, and the computer will restart itself. The computer will operate normally, albeit painfully slow, when MacOS is booted from the internal drive. I didn't notice anything peculiar looking at the activity monitor. What could be causing this? How should I go about diagnosing it?

How do I clone an installation of Windows 10 from macOS?

Posted: 05 Apr 2021 04:35 PM PDT

I have an external SSD which has a working copy of Windows 10 on it. I would like to transfer this copy of Windows 10 onto a different SSD. However, I do not currently have access to a Windows computer.

How would I clone this installation of Windows onto the new SSD? I already have Paragon NTFS installed, which allows me to write to NTFS drives. What should my next step be?

  1. I could drag and drop everything from the Finder into the new SSD. However, this might not copy over some hidden files and might not be a good option.

  2. I could drag and drop after revealing hidden files, but that might also cause issues (?)

  3. I could use rcopy to make sure everything gets copied over (including hidden files), although I don't see any difference between this and option 2.

Note: This question is not necessarily related to BootCamp—I would like to know the same for M1 Macs as well, which do not have BootCamp.

mail.app separate rules for different mail accounts

Posted: 05 Apr 2021 04:07 PM PDT

I have about 10 different mail accounts, connected to mail.app. I want to use separate rules for different accounts. By default, rules apply to all accounts, and if one want any rule to be applies to certain account, one need to create rule with "all conditions met". Say i want to move all notification emails in account1@mail.com account to "notifications" folder of this account. I can't do so with one rule, i need to create rule for every sender's email address. If i will create rule to move notification emails from different addresses to "notification" folder, all emails from all accounts will move to "notification" folder of that particular account. (hope i explained clearly). Maybe it is possible to make rule to work only for certain account with AppleScript?

Will Reset > Delete Data and Settings, prevent recovering my Data? if I am planning to sell my iPhone?

Posted: 05 Apr 2021 05:54 PM PDT

In Windows I know that when you delete a file or even format your PC, then some data can still be recovered from the hard disk using some tools. Now I have iPhone 11 and I am planning to sell it. So I backup my iPhone using iTunes. Then I went to Settings > General > Reset > Erase All Data and settings.

If resetting my iPhone and deleting all the data and apps will prevent someone from recovering my data? Or can other users still recover my data?

If the answer is yes, then what is the best way to permanently delete all the iPhone data before selling it? in Windows I use a tool named fileshredder which will wipe all the free space. Any advice ? Thanks

How to see which services were unloaded using "launchctl unload -w" on macOS?

Posted: 05 Apr 2021 03:25 PM PDT

I ran the following to disable Adobe background services.

BUNDLE_IDENTIFIER_PREFIX="com.adobe"  sudo launchctl unload -w /Library/{LaunchAgents,LaunchDaemons}/$BUNDLE_IDENTIFIER_PREFIX*.plist  launchctl unload -w ~/Library/LaunchAgents/$BUNDLE_IDENTIFIER_PREFIX*.plist  

According to this answer, using launchctl unload -w adds services to override database.

The override database is obscure. How can I see which services were unloaded using "launchctl unload -w" on macOS?

Is it possible to install Windows 10 and Ubuntu on an external SSD on the 2019 16 inch MacBook Pro?

Posted: 05 Apr 2021 04:13 PM PDT

I'm considering buying the 16 inch 2019 MacBook Pro because I need a powerful x86 machine that can run macOS, but I would also be interested in running other operating systems on this computer. I know that the T2 chip is tied to the SSD, and I was wondering if the following configuration is possible, and how I would go along doing it:

  • 2 partitions on the Apple SSD, one running Catalina, and one running Windows 10 through Bootcamp

  • 1 external SSD running big sur

  • 1 external SSD running ubuntu 20.04

If this is possible, how would I do this, and what problems would I face (WiFi, audio, etc)? If this isn't possible, what would I need to do to be able to run these 4 operating systems on this machine, or what other powerful x86 Macs would you recommend?

Script that efficiently listens for changes in Do Not Disturb status

Posted: 05 Apr 2021 09:17 PM PDT

Is it possible to create a script (e.g. applescript) that would listen for changes in DND status and do some actions on each change?

Most examples describe how to change DND status but not how to listen to it.

How to check max allowed open files (ulimit) of a running process (or running app)?

Posted: 05 Apr 2021 07:39 PM PDT

In Linux, I can check the max allowed open files (ulimit) of a process by simply executing

$ cat /proc/<PID>/limits    Limit                     Soft Limit           Hard Limit           Units       Max cpu time              unlimited            unlimited            seconds     Max file size             unlimited            unlimited            bytes       Max data size             unlimited            unlimited            bytes       Max stack size            8388608              unlimited            bytes       Max core file size        0                    unlimited            bytes       Max resident set          unlimited            unlimited            bytes       Max processes             14248                14248                processes   Max open files            1024                 1048576              files       Max locked memory         67108864             67108864             bytes       Max address space         unlimited            unlimited            bytes       Max file locks            unlimited            unlimited            locks       Max pending signals       14248                14248                signals     Max msgqueue size         819200               819200               bytes       Max nice priority         0                    0                      Max realtime priority     0                    0                      Max realtime timeout      unlimited            unlimited            us  

How can I do this in MacOS?

Thanks a lot.

PS1: I knew how to run ulimit commands to check the current ulimit setup. But I don't know how to check and verify those values for a running process.

PS2: I knew how to use lsof to check how many files a process is opening. But it doesn't tell the max number of files a process can open.

iPhone storage is full and stuck into a restart loop

Posted: 05 Apr 2021 10:37 PM PDT

My iPhone XS's storage is full and I removed a couple of applications to free up space, but I thought that a restart could help to delete its cache files... And well, it entered into a reboot loop.

I tried to activate the recovery mode, with no success — is simply continues to reboot by itself and the MacBook does not detect it at all.

Is there any hope to recover the data I have?

How to get Wi-Fi details from menubar in Big Sur like before?

Posted: 05 Apr 2021 11:56 PM PDT

In previous versions of macOS it was possible to get details of the current Wi-Fi connection by command + option clicking the Wi-Fi icon in the menubar. This would show the ip address, WiFi strength, Wi-Fi frequency etc. None of the system icons react to this type of clicking anymore in Big Sur.

Here is a screenshot of how it used to look:

Example Screenshot

Is it possible to restore this behaviour or get something comparable?

How to convert AppleScript URL type to string?

Posted: 05 Apr 2021 06:20 PM PDT

In AppleScript, I can cast some variables (e.g., the clipboard), to the built-in URL type:

set theURL to the clipboard as URL  

If my clipboard contains an RTF link to https://temochka.com/, theUrl will be assigned a raw value like this (which can be seen in the Script Editor replies window):

«data url 68747470733A2F2F74656D6F63686B612E636F6D»  

This last part (68747470733A2F2F74656D6F63686B612E636F6D) is a hex-encoded string that can be decoded as "https://temochka.com". Is there a way to extract just this value? Or maybe get the full URL value out?

Touch ID doesn't work on MacBook Pro 2019

Posted: 05 Apr 2021 11:05 PM PDT

I have troubles with Touch ID on my MacBook Pro 2019 all the time, it just don't recognize my fingers. If I try to add a new fingerprint the red lines animation doesn't show up like nothing is touching the sensor.

How to toggle between "Portrait" and "Landscape Right" orientation in iOS simulators via AppleScript?

Posted: 05 Apr 2021 10:03 PM PDT

How do I toggle between "Portrait" and "Landscape Right" orientation in the iOS simulators via AppleScript?

Cakebrew says "Error: Calling 'brew search' with no arguments to output formulae is disabled!"

Posted: 05 Apr 2021 08:01 PM PDT

I am a new macOS user. I just did a fresh install on an A1398 MacBook Pro and upgraded to Big Sur. As I am used to package managers, I decided to investigate Homebrew and Cakebrew to go along with it. I was able to install Homebrew, with no warnings or errors. Then, I installed Cakebrew with the brew command.

Upon launching Cakebrew, the "All Formulae" list reports the following error:

Error: Calling 'brew search' with no arguments to output formulae is disabled! Use 'brew formulae' instead.

The same error occurs if I execute brew search on the command-line.

Does the new Airpod Max support lossless audio on wireless?

Posted: 05 Apr 2021 11:06 PM PDT

Earlier AirPods and AirPods Pro models send audio over 256kbps AAC.

As I use Tidal HiFi (lossless streaming) and some offline flac/wav files, I still need to use wired headphones, and I need to get 3-4 lightning to 3.5mm jack adapters each year, as they go off often.

I'm thinking about buying the AirPods Max, but it is my belief that AirPods are limited to the same 256kbps AAC recompression as the earlier AirPods.

It seems it uses Bluetooth 5.0 which by itself supports up to 2Mbps, also it may have it's own wireless chip again, so I see the chance, but I'm awaiting confirmation as Apple's marketing page didn't convince me if it's supported or not: https://www.apple.com/uk/airpods-max/

Question: Does someone know if AirPods Max support lossless audio over wireless?

How to delete cache of Microsoft Teams on macOS?

Posted: 05 Apr 2021 11:49 PM PDT

I want to delete the cache of the Microsoft Teams on my Macbook Air.

Please let me know how to do it.

Can I delete files in /Library/Containers/com.apple.mail/Data/Library/Logs?

Posted: 05 Apr 2021 11:23 PM PDT

My MacBook is becoming unstable due to limited disk space the major culprit for which is a mysterious category called "Other". Poking around a bit (a lot actually) I find that I have over 650 GB of Other, 330 GB of which is in a single file in

~/Library/Containers/com.apple.mail/Data/Library/Logs/Mail  

called

imap-mail.outlook.com-<GUID>.txt  

What is this file? Is it safe to delete it?

IPhone Notes App is not loading all my notes but I can search for them from Home screen

Posted: 05 Apr 2021 07:00 PM PDT

I am using the Notes app on iPhone 7 plus running iOS 10.2.1. I don't use icloud. However, a few days ago, the Notes app stopped loading all my notes. My notes app shows nothing. However, when I search for a note using Spotlight Search, I can see the search result. When I tap on it, it opens the Notes app and showing an endless loading animation on the top of screen. Again, it doesn't load the notes. enter image description here Is there any way to fix this problem and recover my notes either by transferring them to a Mac/PC or just fix the Notes app to load all my notes?

Kryptonite iOS automate enter PIN

Posted: 05 Apr 2021 11:57 PM PDT

Kryptonite has the ability to read my PIN from my phone, but recently after I push to GitHub there is a prompt:

Enter PIN for 'Kryptonite iOS':

All I have to do is press enter, but this is an extra step that didn't use to exist.

How can I get rid of this, so it just automatically reads my PIN from my phone? Pressing enter doesn't add any security and the few times I pushed to GitHub and then realized 5 minutes later I never pressed enter is pretty aggravating. FYI, I'm not using Bitbucket.

What is this fancy L with a curl on top, and how could I type it?

Posted: 05 Apr 2021 09:54 PM PDT

I have encountered a very strange, L like letter that I couldn't found in the ASCII table, nor in the Greek alphabet. Do you have any idea what this could be, and what its name is? I would like to type it.

equation with the fancy L as a variable

How can I set Firefox to respect my custom Mac keyboard shortcuts?

Posted: 05 Apr 2021 05:07 PM PDT

In System Preferences, I have D set to Enter Full Screen and Exit Full Screen. I have been using these shortcuts for close to a decade now, and I'm really not interested in relearning them.

enter image description here

Unfortunately, D is also Firefox's built-in shortcut for creating a new bookmark. Unlike most Mac apps I've used, Firefox's built-in shortcut appears to take precedence over my custom one.

How can I make Firefox to respect my D shortcut for entering and exiting fullscreen?

(Small note: I happen to be on a very old version of macOS, specifically 10.9 Mavericks. I don't think this is relevant to the question.)

Remote Desktop 10.2.3 Database Creation Error; 10.2.1 runs fine; 10.2.2 crashes: how to find actual cause(s)?

Posted: 05 Apr 2021 10:12 PM PDT

What would be good steps to find the cause of the below errors?

I get this error when running Microsoft Remote Desktop 10.2.3 or higher on MacOS High Sierra: enter image description here

Database Creation Error    "An error occurred during persistent store migration.    [Domain: NSCocoaErrorDomain, Code: 134110]"  

I am stuck at 10.2.1 now (which cannot add user accounts and will eventually stop working), want to use the newer version, but cannot use intermediate 10.2.2 as it crashes with the below information that I repeatedly submitted with the "Problem Report for Microsoft Desktop".

Manually migrating all the machine and user entries is really cumbersome: there are hundreds of them.

Information that might help:

  • where is the information on entries and users stored?
  • what format is that information stored?
  • are the tools for converting that information between various versions?
  • where are crash reports stored?

Crash report on 10.2.1: https://gist.github.com/jpluimers/851453d938a62ce45abd30fb929ae5e1

display partial file path on Finder tab title

Posted: 05 Apr 2021 04:06 PM PDT

Question

Is there a way to change the Finder tab title to include the name of the containing folder?

Problem

I work on projects that have the same standardized subfolder names (e.g., code), which makes it difficult to switch between projects without going through each tab to identify the containing folder.

Current state: ambiguous Finder tab titles for three different subfolders Ambiguous Finder tab titles for three different folders

Goal

I'd like to display the containing folder name as part of the Finder tab title. Extending the example, this would look like: projectA/code, projectB/code, etc.

Ideal solution (blue text only to emphasize the change): enter image description here

Related questions and resources

In TextEdit or similar editors, is it possible to go to a previous bullet's indent level without a bullet?

Posted: 05 Apr 2021 10:37 PM PDT

I have an issue is with bullets in a rich-text editor. If I want to put several paragraphs under one bullet, like this:

  • Bullet one
  • Bullet two paragraph one

    Bullet two paragraph two

  • Bullet three

I can achieve this by typing ctrlReturn at the end of paragraph one (rather than Return). The beginning of the text that I type after that will indent properly inside the bullet rather than create a new bullet.

But my problem is doing that after a second-level bulleted list, like so:

  • Bullet one
  • Bullet two, first part

    • Inner bullet list, first item.
    • Inner bullet list, second item.

    Bullet two, second part

  • Bullet three

I can't find any way to make the "Bullet two, second part" indent properly to the bullet level without a bullet. The ctrlReturn trick brings me to the inner bullet list level. Trying to tab back from there adds a bullet. Trying to remove the bullet by simply selecting and deleting it seems to work... until I add a new bullet down the list, at which point the bullet is restored.

Is it possible to continue the text of a bullet after a secondary bulleted list, and if so, how?


I'm using Curio, which has text objects that are apparently based on Core Text (rich text editing), and I'm trying to work with bullet lists in it. For all intents and purposes, if there is a solution for TextEdit, it will probably work for me as well.

How do I edit Mac OS X terminal history?

Posted: 05 Apr 2021 03:50 PM PDT

How do I edit my bash history in Mac OS X? I entered a password in that window by mistake and do not want to remove my whole history.

What is a combo update and how is it different than the regular update?

Posted: 05 Apr 2021 07:32 PM PDT

What is a combo update and how is it different from a normal update?

Can I play audio from my iPhone on my Mac?

Posted: 05 Apr 2021 09:55 PM PDT

Can I attach my iPhone 3GS to my Mac Pro so that the iPhone's audio plays through the Mac Pro's speakers?

I can easily attach my Bose headphones so that the music from the iPhone plays through them… that's cool… but I want others to hear the music through my Mac Pro's speaker system.

No comments:

Post a Comment