Usage habit

  • config the Modifier key & shortcuts:
    • turn off off the shortcuts
    • system setting → 键盘 → 键盘快捷键 → 修饰键
  • display all hide files or directory
  1. type on terminal: defaults write com.apple.finder AppleShowAllFiles YES
  2. type on terminal: killall Finder
  • use stat for Mac to monitor Mac system

Addr: https://github.com/exelban/stats

工具

Typora

macOS Typora 0.11.18版: https://download.typora.io/mac/Typora-0.11.18.dmg

Colima

  • 安装 colima
1
brew install colima
  • 安装docker compose
1
brew install docker-compose
  • 自启(使用Homebrew的services命令来管理Colima服务)
1
brew services start colima
  • 定制配置:colima template
    • 打开配置模板(实际上colima template编辑的默认配置被保存在~/.colima/_templates/default.yaml
    • 完成配置模板的编辑后,所有新创建的Colima虚拟机实例都会继承这些默认设置。这样可以确保每个新实例都能以最优的配置启动,无需重复配置。
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# CPU设置
cpu: 8
# 内存设置(以GiB为单位)
memory: 10
# 磁盘大小(以GiB为单位)
disk: 120
# 运行时选择:docker, containerd, incus
runtime: docker
# 是否启用Kubernetes
kubernetes:
enabled: false
# 虚拟机的卷挂载驱动
# virtiofs 仅限于 macOS 和 vmType vz。它是选项中最快的。
mountType: virtiofs
# 为虚拟机指定自定义磁盘镜像。
# 当未指定时,会从https://github.com/abiosoft/colima-core/releases下载适当的磁盘镜像
# 可以指定自定义磁盘镜像的文件路径来覆盖此行为。
diskImage: "/<thepath>/ubuntu-24.04-minimal-cloudimg-arm64-docker.qcow2"
# 虚拟机类型, vz 是 macOS 虚拟化框架,需要macOS 13及以上版本
vmType: vz

# 使用Rosetta进行amd64模拟(需要Mac M1以上和vmType vz)
rosetta: true
# 为虚拟机启用嵌套虚拟化(需要Mac M3以上和vmType vz)
nestedVirtualization: false

# docker daemon的配置,即`daemon.json`
# 例如,配置`registry-mirrors`
docker:
registry-mirrors:
- https://mirror.xxx.com
  • 启动
1
colima start --network-address