Mac-Plan
快捷键
锁屏 : Control + Command + Q
截图 : Shift + Command + 5
刷新 : Command + R
行首 : Command + 左键
行末 : Command + 右键
输入Emoji 表情和颜文字 : Control + Command + space
启动项
代理
权限
由于 macOS 默认情况下只允许运行可信任签名的应用,如果 macOS 阻止运行该软件,请打开 macOS 终端,在新建的终端 Shell 中输入:
由于调用了sudo权限,你可能需要输入密码,会输出如下提示:
此时你需要输入密码,在 Shell 中输入的密码是不可见的,输入完毕后请按回车键。
针对 "已损坏" 的解决办法
苹果系统有一个 GateKeeper 保护机制。
从互联网上下载来的文件,会被自动打上 com.apple.quarantine 标志,我们可以理解为 "免疫隔离"。
系统根据这个附加属性对这个文件作出限制。
随着版本不同,MacOS 对 com.apple.quarantine 的限制越来越严格,在较新 的 MacOS 中,会直接提示 "映像损坏" 或 "应用损坏" 这类很激进的策略。
我们可以通过手动移除该选项来解决此问题。
解锁文件夹
优化
减少程序坞的响应时间
左右光标移动速度
系统偏好设置 -> 键盘 -> 键盘
按键重复:对应的是移动速度;
重复前延迟:对应的是移动前的反应时间。
mac 下 sudo 用 touchid 代替密码输入
保存的时候可能要用 :wq!
来自文章: https://sixcolors.com/post/2020/11/quick-tip-enable-touch-id-for-sudo/
软件
Rosetta 2
chrome
https://www.google.com/chrome/
clash
https://github.com/Fndroid/clash_for_windows_pkg/releases
homebrew
https://brew.sh/index_zh-cn
https://gitee.com/cunkai/HomebrewCN
然后使用 brew install xxx
就可以安装应用了,也可以使用 brew uninstall xxx
卸载软件
nodejs
git
ffmpeg
motrix
https://github.com/agalwood/Motrix
腾讯柠檬清理
https://lemon.qq.com/
snipaste
https://zh.snipaste.com/
tabby
https://github.com/Eugeny/tabby
wgestures2
https://www.yingdev.com/projects/wgestures2#
vlc
https://www.videolan.org/index.zh.html
edge
https://www.microsoft.com/en-us/edge
Alfred
https://www.alfredapp.com/
code-server
https://github.com/coder/code-server
python
默认自带 python2 和 python3
java
https://oracle.com/java/technologies/downloads/#java8-mac
https://www.azul.com/downloads/?os=macos&architecture=arm-64-bit
javafx
https://openjfx.io/
https://openjfx.cn/dl/
go
php
先查询有哪些 php 的版本,M1 目前只支持部分版本
这里我安装 php7.3,参考 stackoverflow 的回答 https://stackoverflow.com/questions/70417377/error-php7-3-has-been-disabled-because-it-is-a-versioned-formula
安装完毕后应该就可以在 /opt/homebrew/etc/php/7.3/
目录下看到 php 了
运行以下命令加入到环境变量中
brew info php
可以查看我们安装的 php 信息
jenv
https://github.com/jenv/jenv
miniforge
https://github.com/conda-forge/miniforge
pyenv
CotEditor
https://github.com/coteditor/CotEditor
nginx
管理 nginx 运行状态
默认 www 目录
配置文件所在目录
cloudflared
cmake
ip
tiles
https://freemacsoft.net/tiles/
alt-tab-macos
https://github.com/lwouis/alt-tab-macos
espanso
https://github.com/espanso/espanso
https://espanso.org/docs/get-started/
一些依赖
libpq.5.dylib
搜索发现这个应该是 postgresql 相关功能依赖的文件
一种方法是直接安装 postgresql,不过我测试了没成功
我在本地用 fzf 搜索发现 System/Volumes/Data/opt/homebrew/lib/libpq.5.dylib 路径有这个文件,那么复制一个好了,建立个软连接也行
参考
https://github.com/PostgresApp/PostgresApp/issues/83
https://blog.csdn.net/yutianyue126/article/details/106911948
libssl.1.1.dylib
参考
https://www.v2ex.com/t/666738
https://pavcreations.com/dyld-library-not-loaded-libssl-1-1-dylib-fix-on-macos/
https://stackoverflow.com/questions/59006602/dyld-library-not-loaded-usr-local-opt-openssl-lib-libssl-1-0-0-dylib
libcrypto.1.1.dylib
xcrun: error: invalid active developer path
环境变量
和 linux 是一样的,比如装 maven ,下载解压放到 Library 下,添加环境变量
可以长期修改