Cheatsheets are all you need

计算机上有很多工具都可以通过命令行的方式调用。想要快速入门一个工具,我们第一反应可能是去找一个教程,但互联网上教程的质量层次不齐,有的废话连篇,有的鞭辟入里但是从盘古开天地开始讲;也可能是直接去找官方文档,然后发现有的文档一上来列个几十个命令行参数,人直接傻了。 ...

September 30, 2026 · 2 min · 797 words · Square Zhong

Git: Version Control of the World

Introduction Agents write all the code, but I still make the Git commits. That’s my last remaining contribution. (T_T) Treat this as a Git quick reference, though it could also serve as a tutorial. The official cheat sheet is much better than mine. Working tree, index, and HEAD flowchart TD W["Working tree: files on disk"] -->|"git add"| I["Index: staged snapshot"] I -->|"git commit"| C["Commits"] I -->|"git restore"| W subgraph LOCAL["Local repository"] H["HEAD"] -.->|"normally refers to"| B["Current branch"] B -.->|"points to"| C end Working tree: the files you edit on disk. Index (staging area): the snapshot prepared for the next commit. Local repository: stored objects, including commits, and references such as branches. HEAD: normally refers to the current branch, which points to a commit. With a detached HEAD, it points directly to a commit. Lazygit I recommend Lazygit, a terminal user interface (TUI) for convenient Git operations. ...

June 1, 2025 · 8 min · 1645 words · Square Zhong