From 06acacb52445c60ce760c0091563517d2172c8ab Mon Sep 17 00:00:00 2001
From: moomiji <35213527+moomiji@users.noreply.github.com>
Date: Sun, 6 Oct 2024 22:58:12 +0800
Subject: [PATCH] docs: NuGet.config & README
---
.gitignore | 3 ---
NuGet.config | 17 +++++++++++++++++
README.md | 15 ++++++++++-----
README_zh.md | 13 +++++++++----
4 files changed, 36 insertions(+), 12 deletions(-)
create mode 100644 NuGet.config
diff --git a/.gitignore b/.gitignore
index 1e12b0f..0cf807d 100644
--- a/.gitignore
+++ b/.gitignore
@@ -252,9 +252,6 @@ PublishScripts/
*.nuget.props
*.nuget.targets
-# Nuget personal access tokens and Credentials
-nuget.config
-
# Microsoft Azure Build Output
csx/
*.build.csdef
diff --git a/NuGet.config b/NuGet.config
new file mode 100644
index 0000000..4958352
--- /dev/null
+++ b/NuGet.config
@@ -0,0 +1,17 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/README.md b/README.md
index 35423fa..3344baf 100644
--- a/README.md
+++ b/README.md
@@ -66,25 +66,30 @@ dotnet add package Maa.Framework --prerelease
#### Nightly Build
-Download `nupkgs.zip` from [CI Action](https://github.com/MaaXYZ/MaaFramework.Binding.CSharp/actions/workflows/ci.yml) and extract files to `.\nupkgs\`.
+##### Add package
- shell
``` ps1
-dotnet add package Maa.Framework --prerelease -s .\nupkgs\
+dotnet add package Maa.Framework --prerelease -s https://nuget.pkg.github.com/maaxyz/index.json
```
-- or .csproj
+##### Add package source
+
+- .csproj
``` xml
- $(RestoreSources);$(FullPath of .\nupkgs\)
+ $(RestoreSources);https://api.nuget.org/v3/index.json;https://maaxyz.github.io/pkg/nuget/index.json
```
+- NuGet.config
+Please refer to [this config](../NuGet.config) for example, and [this article](https://maaxyz.github.io/MaaFramework.Binding.CSharp/articles/preview.html) for complete information.
+
#### Specifying RIDs
The supported Runtime IDs for `MaaFramework` can be found [here](https://github.com/MaaXYZ/MaaFramework/tree/main/tools/nupkgs).
-To use specific RIDs, such as the supported `win` platform packages, manually reference the following packages:
+To use specific RIDs, such as the supported `win` platform packages, please manually reference the following packages:
- `Maa.Framework.Native`
- `Maa.Framework.Runtime.win-arm64`
- `Maa.Framework.Runtime.win-x64`
diff --git a/README_zh.md b/README_zh.md
index 1f745db..c0ee59c 100644
--- a/README_zh.md
+++ b/README_zh.md
@@ -66,20 +66,25 @@ dotnet add package Maa.Framework --prerelease
#### 夜间构建
-从 [CI Action](https://github.com/MaaXYZ/MaaFramework.Binding.CSharp/actions/workflows/ci.yml) 下载 `nupkgs.zip` 并解压文件到 `.\nupkgs\` 。
+##### 添加包
- shell
``` ps1
-dotnet add package Maa.Framework --prerelease -s .\nupkgs\
+dotnet add package Maa.Framework --prerelease -s https://nuget.pkg.github.com/maaxyz/index.json
```
-- or .csproj
+##### 添加包源
+
+- .csproj
``` xml
- $(RestoreSources);$(FullPath of .\nupkgs\)
+ $(RestoreSources);https://api.nuget.org/v3/index.json;https://maaxyz.github.io/pkg/nuget/index.json
```
+- NuGet.config
+例子请参考[该配置](../NuGet.config),完整信息请参考[该文章](https://maaxyz.github.io/MaaFramework.Binding.CSharp/articles/preview.html)。
+
#### 指定 RIDs
`MaaFramework` 目前支持的 Runtime Id 可在[此处](https://github.com/MaaXYZ/MaaFramework/tree/main/tools/nupkgs)查询。