Mac系统的使用_5


=Start=

最近在逛博客的时候发现的一些Mac使用技巧:

一、Mac上查看Wi-Fi密码

1.要访问 Wi-Fi 密码你需要知道自己的管理员用户名、密码,和要查看的 Wi-Fi 网络的名称。在终端中,复制并粘贴以下命令:

security find-generic-password -ga "WiFiNAME" | grep "password:"

将”WiFiNAME”更换为你要寻找密码的对应无线网络名称。

2.输入回车,然后系统会要求你输入用户名和密码。

这些信息是用于访问你的钥匙串,并提供你要找寻的密码,当输入正确的信息后,终端就会显示出对应的 Wi-Fi 密码。

二、Mac上怎么样把「Desktop」文件夹命名为「桌面」

打开终端,输入以下命令:

touch ~/Desktop/.localized
touch ~/Downloads/.localized
三、Mac上如何快速「显示桌面」

记得在Windows7上可以通过鼠标点击桌面右下角的一小块区域达到快速跳转至桌面的功能(好像命令「Win + d」也行),在Mac上可以通过下面的组合键达到快速「显示桌面」并返回的功能:

「fn + F11」

参考链接:
更多参考链接:

=EOF=

, ,

《“Mac系统的使用_5”》 有 29 条评论

  1. macOS上一些好用的应用程序、软件以及工具列表
    https://github.com/iCHAIT/awesome-macOS

    macOS安全和隐私指导
    https://github.com/drduh/macOS-Security-and-Privacy-Guide
    【技术分享】MacOS安全加固指南
    http://bobao.360.cn/learning/detail/3136.html
    http://newosxbook.com/files/moxii3/AppendixA.pdf

    极好的开源Mac应用
    https://github.com/jeffreyjackson/mac-apps

    一些不错的Mac屏保应用
    https://github.com/aharris88/awesome-macos-screensavers

    不错的Mac默认配置
    https://github.com/kevinSuttle/macOS-Defaults

    一键将你的Mac配置成适合Web开发的环境
    https://github.com/monfresh/laptop
    https://github.com/18F/laptop

    一些有用的Mac 脚本、文档、快捷键
    https://github.com/superhj1987/awesome-mac-things

    一些不错的Mac应用
    https://github.com/xyNNN/awesome-mac

  2. site:zhihu.com mac 制图 工具
    ==
    Mac上有哪些好用的画图软件可以推荐?
    https://www.zhihu.com/question/30749056
    Mac上最好用的流程图软件是什么?
    https://www.zhihu.com/question/19588698
    Mac下有如Visio一样好用的流程图软件吗?
    https://www.zhihu.com/question/20273326
    ==
    亿图(EdrawMax)
    https://www.edrawsoft.com/cn/download-edrawmax.php

    Gliffy Diagrams(Chrome扩展,可离线)
    https://chrome.google.com/webstore/detail/gliffy-diagrams/bhmicilclplefnflapjmnngmkkkkpfad

    ProcessOn(在线制作)
    https://www.processon.com/

    • 在 Mac 上导入和导出备忘录
      https://support.apple.com/zh-cn/guide/notes/not201900c07/mac

      macOS「备忘录」导出和备份的 3 种方法
      https://www.sysgeek.cn/backup-macos-notes/
      `
      苹果的「备忘录」应用程序是一款非常不错的工具,它可以快速记录信息、维护列表清单、收集你的灵感及想法。随着内容的不断填充,「备忘录」里面存储的内容也会越来越多,变得越来越重要,这也让对 macOS「备忘录」进行导出和备份变成了不少用户的刚需。

      如果你在苹果设备上启用了 iCloud,那么默认「备忘录」会被自动同步到云端,如果你没启动 iCloud 又想在 macOS 上对「备忘录」进行手动备份,可以参考以下步骤。

      方法一:将「备忘录」导出为 PDF 文件
      (将笔记导出为 PDF 文件的好处是它保留了笔记的原始格式和结构,但每次只能导出一条笔记内容,如果你要导出的内容太多,操作起来十分繁琐。虽然 PDF 存储起来十分方便,但编辑起来不太方便,也无法直接从 PDF 去恢复「备忘录」。)

      方法2:将「备忘录」笔记内容复制到 RTF 文档中
      备份 macOS「备忘录」内容的另一种方法是,手动将每个便笺复制并粘贴到富文本文档中,然后将文件保存为 RTF 文件。 也可以用复制/粘贴的办法将「备忘录」的内容保存在另一个文字处理器中,例如 Microsoft Word、Apple Pages 等。
      这种方法的优点是,任何文本编辑器都可以轻松读取文件,并且保留了再次编辑能力。在需要时,还可以将 RTF 文件中的内容复制并粘贴回「备忘录」里。但是,这样操作会比较麻烦,而且会感觉傻傻的,不是创建备份的理想方法。

      方法3:直接备份 macOS「备忘录」数据库
      「备忘录」会将所有数据保存在 macOS 的特定文件夹中,而且该文件夹还处于隐藏状态。实际上「备忘录」的数据被保存在 SQLite 数据库中,不能作为普通文本文件访问,但我们可以将整个目录搬家到安全的地方进行备份。

      ~/Library/Group\ Containers/group.com.apple.notes

      此文件夹包含本地存储在 macOS 上的所有笔记,将整个文件夹及其内容复制到安全的地方,可以将其用作备份。
      备份整个目录后,如果出现任何问题,可以将其放回原来的位置,就可以恢复到备份时的状态。 此外,如果您有 iCloud 备忘录,则需要使用相同的 Apple ID 才能使用此方法访问其中一些笔记。
      `

      macOS 如何批量导出 notes (备忘录)的内容?
      https://www.zhihu.com/question/356340737
      `
      搜了一下,没有直接导出的方法。如果只是为了备份的话,可以定期备份 ~/Library/Group Containers/group.com.apple.notes 这个文件夹里面的内容。万一出问题可以恢复这个文件夹就好。
      照理,如果备忘录通过iCloud同步了的话,要备份的必要性没那么大。
      `

  3. 将第三方蓝牙配件与 iPhone、iPad 或 iPod touch 配对
    https://support.apple.com/zh-cn/HT204091
    `
    将设备与蓝牙配件配对
    1. 在 iOS 设备上,前往“设置”>“蓝牙”,然后开启“蓝牙”。停留在这个屏幕,直到完成配件的配对步骤。
    2. 将您的配件置于发现模式,等待它显示在您的 iOS 设备上。如果您没有看到这个配件,或不清楚如何使它处于可被发现的状态,请查看配件随附的说明,或联系制造商。
    3. 要进行配对,请轻点出现在屏幕上的配件名称。您可能需要输入 PIN 码或密码。如果您不知道 PIN 码或密码,请查看配件随附的文档。

    将配件配对后,您可以将这个配件与您的 iOS 设备搭配使用。要配对多个蓝牙配件,请重复这个部分中的步骤。
    `

    将蓝牙设备与 Mac 相连
    https://support.apple.com/zh-cn/guide/mac-help/blth1004/mac
    `
    在 Mac 上,选取苹果菜单 >“系统偏好设置”,然后点按“蓝牙”。
    选择列表中的设备,然后点按“连接”。
    `

  4. ssh的连接复用设置
    https://stackoverflow.com/questions/20410252/how-to-reuse-an-ssh-connection
    https://www.cyberciti.biz/faq/linux-unix-reuse-openssh-connection/
    `
    $ vim ~/.ssh/config
    ++++
    host *
    ControlMaster auto
    ControlPath ~/.ssh/ssh_mux_%h_%p_%r
    ++++
    `
    https://www.tecmint.com/speed-up-ssh-connections-in-linux/
    `
    1. Force SSH Connection Over IPV4
    2. Disable DNS Lookup On Remote Machine
    3. Reuse SSH Connection
    4. Use Specific SSH Authentication Method
    `

  5. 你的 Mac 用对了吗?推荐一些 Mac 上比较好用的软件
    https://juejin.im/post/5b3c694f6fb9a04fb309d959
    `
    1. 日常工具

    2. 效率工具
    Alfred
    Todoist
    Paste
    Synergy
    Feedly、Reeder
    MindNode
    1Password

    3. 系统工具
    Tuxera NTFS For Mac
    VMware、Parallels Desktop
    CleanMyMac

    4. 编辑器
    JetBrains
    Sublime
    MarkEditor
    SnippetLab
    Beyond Compare

    5. 管理工具
    Filezilla
    ForkLift
    SSH Shell
    HomeBrew、CakeBrew

    6. 影音图像
    IINA
    ScreenFlow
    iPic
    PixelMator
    Polarr Photo Editor
    Boom2

    7. 趣味扩展
    Tickeys
    Duet

    8. Tips
    `

  6. 2019年最好用的云笔记软件推荐
    https://www.v1tx.com/post/best-note-software/
    `
    印象笔记
    有道云笔记
    为知笔记
    OneNote
    Notion
    蚂蚁笔记
    Simplenote
    Bear熊掌记(macOS、iOS)

    # 最后的建议
    首先推荐给大家的是印象笔记,免费、稳定、而且功能很多,适合大部分人使用

    国内的软件首推有道云笔记,网易出品、大空间、颜值高

    OneNote这款软件给人的感觉和Office办公套件一样,很强大,适合笔记重度用户使用

    如果你想要做知识库,或者记录一切东西,可以尝试使用Notion

    蚂蚁笔记比较适合喜欢技术的人使用,数学公式、Markdown等,可以自建、也可以使用他们的服务

    如果你喜欢Markdown,而且在用苹果系统的话,推荐使用熊掌记
    `

  7. 这 4 款笔记软件,总有一款适合你
    https://www.lizhi.io/blog/78235407
    `
    OneNote [Mac/Win/iOS/Android]
    印象笔记 [Mac/Win/iOS/Android]
    Bear [Mac/iOS]
    Simplenote [Mac/Win/iOS/Android]
    `

    求推荐 Mac 的笔记软件,Evernote 除外
    https://www.v2ex.com/t/142355?p=2

    日经一波, mac 上更适合的笔记软件
    https://www.v2ex.com/t/361618

    如何系统性地做笔记–Onenote,Evernote,Ulysses对比
    https://www.jianshu.com/p/e97516e8aa26

    笔记软件的选择,我最终还是回归到了系统备忘录
    https://sspai.com/post/36991

  8. 为什么电脑没有 GPS?是否需要?为什么?
    https://www.zhihu.com/question/20834002
    `
    GPS 的正确高效定位依赖于可以直视天空的无遮挡视野。电脑通常位于室内,所以并不合适。

    室内无法收到 GPS 卫星的信号,无法通过 GPS 进行定位。只能通过其他方式(例如WiFi定位)。鉴于电脑通常在室内使用,电脑上的 GPS 无法正常工作。

    笔记本安装gps的需求真的不大,并不是难度大,而是需求方太少
    `

    How does a MacBook pro locate itself?
    https://discussions.apple.com/thread/4366180

    Does the MacBook Pro have a GPS chip inside of it?
    https://www.quora.com/Does-the-MacBook-Pro-have-a-GPS-chip-inside-of-it
    `
    MacBook Pro or any other Mac products doesn’t have any GPS chip embedded into the device by the Apple. They use your Wi-Fi hotspot or internet connection to determine you location which isn’t as accurate a GPS bur good enough.

    However if you are using Google Maps on your mobile phone (Mostly if Android) and also use the Google Maps on the Macbook Pro with same google account then the location of your mobile phone may be used to track the location on your Macbook Pro.

    MacBook Pro或任何其他Mac产品都没有内置任何苹果公司的GPS芯片。它们利用你的Wi-Fi热点或互联网连接来确定你的位置,这虽然不如GPS精确,但也足够了。

    然而,如果你在你的手机上使用谷歌地图(大部分是Android),也使用相同谷歌帐户的Macbook Pro上的谷歌地图,那么你手机的位置可能会被用来跟踪你的Macbook Pro上的位置。
    `

  9. 什么是UserEventAgent,它为什么在Mac上运行?
    https://blog.csdn.net/culiuman3228/article/details/108781227
    https://www.howtogeek.com/338994/what-is-usereventagent-and-why-is-it-running-on-my-mac/

    什么是configd?为什么在Mac上运行?
    https://blog.csdn.net/culinqian4296/article/details/108781314
    https://www.howtogeek.com/338196/what-is-configd-and-why-is-it-running-on-my-mac/

    What Is This Process and Why Is It Running on My Mac?
    https://www.howtogeek.com/312671/what-is-this-process-and-why-is-it-running-on-my-mac/
    `
    What Is kernel_task, and Why Is It Running on My Mac?
    What Is hidd, and Why Is It Running on My Mac?
    What Are mds and mdworker, and Why Are They Running on My Mac?
    What Is installd, and Why Is It Running on My Mac?
    What Is the Process WindowServer, and Why Is It Running on My Mac?
    What Is blued, and Why Is It Running on My Mac?
    What Is launchd, and Why Is It Running on My Mac?
    What Is backupd, and Why Is It Running on My Mac?
    What Is dbfseventsd and Why Is It Running on My Mac?
    What Is opendirectoryd, and Why Is It Running on My Mac?
    What is coredaudiod, and Why Is It Running on My Mac?
    What is powerd, and Why Is It Running on My Mac?
    What is coreauthd, and Why Is It Running on My Mac?
    What is configd, and Why Is It Running on My Mac?
    What is UserEventAgent, and Why Is It Running on My Mac?
    What is nsurlstoraged, and Why Is It Running on My Mac?
    What is parentalcontrold and Why Is It Running on My Mac?
    What is sandboxd and Why Is It Running on My Mac?
    What is cloudd and Why Is It Running on my Mac?
    What Are assistant_service and assistantd, and Why Are They Running on my Mac?
    What is storddownloadd and Why Is It Running on my Mac?
    What is dasd and Why Is It Running on my Mac?
    What is AppleSpell and Why is it Running on my Mac?
    `

  10. macOS 如何限制进程 CPU 占用
    https://sspai.com/post/67331
    `
    很早之前大家就发现,macOS 的活动监视器真的就只是一个监视器,并不能像 Windows 的任务管理器那样可由用户手动设置进程的优先级。但当我们真的有这样的需求时,该怎么办呢?

    我们知道,其实苹果的 macOS 是一个半开半闭源的操作系统,大致来讲,GUI 部分是闭源的,这也是 macOS 的精髓;核心系统部分(darwin-xnu)是开源的。这使得用户或者说开发者依然有机会进行系统调用,以实现需求——限制某个进程的 CPU 资源占用。

    也许你会好奇,什么人会有这种需求呢?当某些公司强制要求员工们安装「xx 安全软件」并且时不时还在后台疯狂扫描文件吃 CPU,还不准你关闭和卸载的时候,你就有这个需求了。

    方案一:cputhrottle
    方案二:AppPolice
    方案三:App Tamer
    方案四:Turbo Boost Switcher

    # 探索
    由于 cputhrottle 的源码比较少,我就稍微看了看,发现核心逻辑还是不复杂的,会根据指定进程的 CPU 使用时间来采样,计算出需要控制的占比,最终通过系统调用(Mach 内核 task 相关的接口,这个 task 在 macOS 的内核中相当于进程的概念)来挂起 task,并休眠一定的时间,达到让出 CPU 资源的目的。
    `
    http://www.willnolan.com/cputhrottle/cputhrottle.html
    https://github.com/AppPolice/AppPolice
    https://www.stclairsoft.com/AppTamer/
    http://tbswitcher.rugarciap.com/

  11. macOS上一些系统自带应用所在的目录位置:
    `
    /System/Applications/TextEdit.app/Contents/MacOS/TextEdit
    /System/Applications/Notes.app/Contents/MacOS/Notes

    可以通过「finder」进入「应用程序」然后鼠标选中你想查看的应用再通过快捷键/鼠标右键「复制」,再去终端上「粘贴」就可以看到实际的目录了。

    $ ls -l /System/Applications
    App Store.app
    Calculator.app
    Contacts.app
    FindMy.app
    Image Capture.app
    Maps.app
    Music.app
    Photo Booth.app
    Preview.app
    Siri.app
    System Preferences.app
    Time Machine.app
    Automator.app
    Calendar.app
    Dictionary.app
    Font Book.app
    Launchpad.app
    Messages.app
    News.app
    Photos.app
    QuickTime Player.app
    Stickies.app
    TV.app
    Books.app
    Chess.app
    FaceTime.app
    Home.app
    Mail.app
    Mission Control.app
    Notes.app
    Podcasts.app
    Reminders.app
    Stocks.app
    TextEdit.app
    VoiceMemos.app
    Utilities/

    $ ls -l /System/Applications/Utilities
    Activity Monitor.app
    AirPort Utility.app
    Audio MIDI Setup.app
    Bluetooth File Exchange.app
    Boot Camp Assistant.app
    ColorSync Utility.app
    Console.app
    Digital Color Meter.app
    Disk Utility.app
    Grapher.app
    Keychain Access.app
    Migration Assistant.app
    Screenshot.app
    Script Editor.app
    System Information.app
    Terminal.app
    VoiceOver Utility.app
    `

  12. 安装了不受苹果认证的描述性文件有哪些风险?
    https://www.zhihu.com/question/46343793
    `
    描述文件,为后面铺路的例子,比如他可以在用户不知的情况下开启远程管理/文件共享(系统偏好设置 > 共享),或者准许某个软件的隐私访问 (完全磁盘访问 / 屏幕录制等) 权限 (系统偏好设置 > 安全性与隐私 > 隐私) 等服务。

    隐私的安全设施的目的在于,任何一个需要访问设计用户隐私的数据/设备时,都需要明确的用户知晓的情况下的认可,也就是要弹出确认框后,用户点击许可,才可以访问。如果使用描述文件,那么就可以绕过用户许可这一步。那么,除了是企业自己的或自愿被企业管理的Mac除外,其它个人使用的Mac,除非是安装软件时自己认可的,都不该有描述文件。所以,如果是未知的,就应该删除。

    如果是买的二手Mac,而且被安装了描述文件,如果是从所属企业正常渠道购买的,需要联系该公司的技术部门,将这台机器从他们的管理数据库中删除,然后重装系统;如果从其它渠道购买,那么很可能是买到了丢失的机器,那么就要拒绝购买,或者甚至报警。

    描述文件可以安装根证书,安装后,系统就是信任该根证书,这样的潜在问题是,用该根证书签名的证书都会被系统自动信任,而不会提醒。如果被恶意安装,那么小心不安全的代码就可能被执行。所以,一定要小心。
    `

  13. 在 Mac 上的“钥匙串访问”中获取有关证书的信息
    https://support.apple.com/zh-cn/guide/keychain-access/kyca15178/mac
    `
    1. 在 Mac 上的“钥匙串访问” App 中,选择一个钥匙串,然后点按“我的证书”或“证书”类别来查看该钥匙串中的证书。

    2. 选择想要查看的证书,然后点按工具栏中的“简介”按钮。您也可以连按想要查看的证书。
    `

    在 Mac 上查看储存在钥匙串中的信息
    https://support.apple.com/zh-cn/guide/keychain-access/kyca1085/mac

    mac通过命令行获取证书和配置文件过期时间
    https://www.cnblogs.com/meitian/p/7764420.html

  14. How to Know What Is Safe to Quit on Mac? Use Activity Monitor
    https://macmyths.com/activity-monitor-mac-what-to-quit/
    `
    hidd: hidd stands for Human Interface Device Daemon. The purpose of the hidd daemon is to respond to input devices such as mouse and keyboard.
    Terminating hidd will temporarily block Mac from responding to mouse and keyboard, but macOS will restart the daemon shortly.
    sysmond: sysmond stands for System Monitor daemon. This is actually the service that Activity Monitor is using to get the readings from the system. If it causes high CPU usage with the process, simply quit the Activity Monitor.
    powerd: As its name implies, powerd is a daemon responsible for power and energy-saving features in Mac, e.g., when Mac can go to sleep and when it should wake up. If terminated, the process will restart again.
    coreaudiod: As its name implies coreaudiod responsible for sound features (speakers and microphone) on Mac. Sometimes it’s ok to terminate and restart the daemon if you are having issues with the sound on the Mac.
    cloudd: Cloudd is the daemon responsible for iCloud activities such as syncing cloud and local files. It is normal for the daemon to use CPU when there are many files that need to be synced.
    ctkd: ctkd is a daemon responsible for Smart Cards. If it’s using too much CPU then terminate it.
    mdnsresponder: mdnsresponder is a daemon that scans your local network for devices compatible with your Mac. If it takes too much CPU, it’s safe to terminate it.
    mds: mds stands for metadata server, and it’s a part of Spotlight Search indexing. It is perfectly normal when it is using a lot of CPU because it’s indexing files on the disk to make sure that Spotlight Search works correctly.
    watchdogd: watchdogd is a daemon responsible for restarting Mac in case if it gets into an unrecoverable situation. If it’s burning the CPU, it’s best to restart the Mac.
    `

  15. Bob 是一款 macOS 平台翻译和 OCR 软件。
    https://github.com/ripperhe/Bob
    `
    翻译功能:

    * 划词翻译
    * 截图翻译
    * 输入翻译
    * 翻译多开
    * 自定义插件
    * 自动识别语种
    * 驼峰拆分、蛇形拆分
    * AppleScript 调用
    * PopClip 调用

    OCR 功能:
    * 截图 OCR
    * 静默截图 OCR
    * 访达选图 OCR
    * 离线识别
    * 连续识别
    * 二维码识别
    * 自动复制
    * 智能分段
    `

  16. 在macOS上如何通过命令行进行OCR识别?

    使用Homebrew安装 tesseract
    `
    $ brew install tesseract
    $ brew install tesseract-lang

    # 如果不安装语言包,则在识别除了英语之外的语言时,会报错
    Error opening data file /usr/local/share/tessdata/chi_sim.traineddata
    Please make sure the TESSDATA_PREFIX environment variable is set to your “tessdata” directory.
    Failed loading language ‘chi_sim’
    `

    Tesseract Command Line Usage
    https://tesseract-ocr.github.io/tessdoc/Command-Line-Usage.html
    `
    # 将识别结果输出到 output.txt 中
    tesseract input.png output –oem 1 -l eng
    tesseract input.png output –oem 0 -l eng

    # 将识别结果直接打印到终端上
    tesseract input.png – -l eng

    # 指定多种语言(中文+英文)
    tesseract input.png output -l chi_sim+eng
    `

  17. How to export/backup Notes in macOS in one go
    https://apple.stackexchange.com/questions/357495/how-to-export-backup-notes-in-macos-in-one-go
    `
    You can use a third-party app called Notes Exporter to export all notes in one go. After granting access to the Notes data, the app exports each individual note as a separate text file in the location of your choosing.
    你可以使用一款名为 “笔记导出器 “的第三方应用程序一次性导出所有笔记。授权访问备忘数据后,该应用程序会将每条备忘导出为单独的文本文件,文件位置由您选择。

    The only limitation being that you’ll need to re-import them one by one if you wish to use them on a new machine.
    唯一的限制是,如果你想在新机器上使用它们,就需要逐个重新导入。

    A better and much simpler approach, if you have the necessary storage space available would be to use iCloud to sync them to the new machine.
    如果你有必要的存储空间,更好、更简单的方法是使用 iCloud 将它们同步到新机器上。

    Note: No affiliation whatsoever to the developer of the app.
    注:与应用程序开发商无任何关联。
    `
    Export all your notes from Apple Notes to Markdown/HTML with attachments.
    http://falcon.star-lord.me/exporter/

    The Best Way to Bulk Export Your Apple Notes
    https://lifehacker.com/the-best-way-to-bulk-export-your-apple-notes-1850685680
    `
    准备批量导出笔记时,请从 Mac App Store 下载 Exporter。安装完成后,打开 Exporter 并点击向下箭头图标。您将被要求选择一个文件夹来存储所有导出的笔记,一旦您选择了该文件夹,Exporter 就会显示一个进度条,并开始下载所有内容。Exporter 可根据您自己的文件夹结构对笔记进行整齐分类,并有单独的子文件夹用于存储图片和附件。默认导出格式为 “md”,代表 Markdown。这对于文本笔记来说已经足够好了,但它不能显示这些笔记中的嵌入图片。这些文件存储在单独的文件夹中。

    如果您更喜欢在笔记中看到嵌入的图片,请打开导出器,单击顶部栏中的格式菜单,然后选择 HTML。现在导出您的所有笔记,您会发现所有笔记本身都显示了图片和其他媒体。

    现在,您可以使用您最喜爱的笔记应用提供的导入工具来移动这些笔记。并非每个笔记应用都支持我们选择的导出格式,但最好的应用(如 Obsidian 和 Bear)都支持这些格式。
    `

回复 hi 取消回复

您的电子邮箱地址不会被公开。 必填项已用*标注