From adedd14dd85149aa1fe518821acb24bc2622845e Mon Sep 17 00:00:00 2001 From: jinzhongjia Date: Tue, 28 Nov 2023 23:20:03 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0fetch=E6=96=B0=E7=9A=84?= =?UTF-8?q?=E8=AF=B4=E6=98=8E?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- learn/environment/zig-command.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/learn/environment/zig-command.md b/learn/environment/zig-command.md index ad276854..fd054f34 100644 --- a/learn/environment/zig-command.md +++ b/learn/environment/zig-command.md @@ -78,3 +78,11 @@ outline: deep $ zig fetch https://github.com/limine-bootloader/limine-zig/archive/trunk.tar.gz 12202809180bab2c7ae3382781b2fc65395e74b49d99ff2595f3fea9f7cf66cfa963 ``` + +当然如果你想将包直接添加到 `zon` 中,你可以附加 `--save` 参数来实现效果: + +```zig +zig fetch --save https://github.com/limine-bootloader/limine-zig/archive/trunk.tar.gz +// 当包提供 name 时,会自动使用包的 name +// 当然,你也可以指定包的 name,使用 --save=limine +```