From d1805dd6aa57f42f8fa01c2ca71f58291fce2e1a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E7=8E=8B=E5=B7=9E=E5=9F=8E?=
<36623158+SeWZC@users.noreply.github.com>
Date: Tue, 23 Jan 2024 14:57:41 +0800
Subject: [PATCH 1/5] =?UTF-8?q?=E5=8D=87=E7=BA=A7=20Microsoft.CodeAnalysis?=
=?UTF-8?q?.CSharp=20=E5=88=B0=E6=9C=80=E6=96=B0=E7=A8=B3=E5=AE=9A?=
=?UTF-8?q?=E7=89=88=E6=9C=AC=204.8.0=20=E4=BB=A5=E6=94=AF=E6=8C=81?=
=?UTF-8?q?=E6=96=B0=E8=AF=AD=E6=B3=95?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
版本 4.8.0 包含了对 C# 12 的支持:https://github.com/dotnet/roslyn/blob/main/docs/wiki/NuGet-packages.md#versioning
同时升级了 System.Memory
---
src/SourceFusion.Tool/SourceFusion.Tool.csproj | 4 ++--
.../dotnetCampus.Telescope.SourceGeneratorAnalyzers.csproj | 2 +-
.../dotnetCampus.TelescopeTask.csproj | 4 ++--
3 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/src/SourceFusion.Tool/SourceFusion.Tool.csproj b/src/SourceFusion.Tool/SourceFusion.Tool.csproj
index d826908..cc24a07 100644
--- a/src/SourceFusion.Tool/SourceFusion.Tool.csproj
+++ b/src/SourceFusion.Tool/SourceFusion.Tool.csproj
@@ -27,8 +27,8 @@
-
-
+
+
diff --git a/src/TelescopeSourceGenerator/Analyzers/dotnetCampus.Telescope.SourceGeneratorAnalyzers.csproj b/src/TelescopeSourceGenerator/Analyzers/dotnetCampus.Telescope.SourceGeneratorAnalyzers.csproj
index 08d6622..782df9e 100644
--- a/src/TelescopeSourceGenerator/Analyzers/dotnetCampus.Telescope.SourceGeneratorAnalyzers.csproj
+++ b/src/TelescopeSourceGenerator/Analyzers/dotnetCampus.Telescope.SourceGeneratorAnalyzers.csproj
@@ -16,7 +16,7 @@
-
+
diff --git a/src/dotnetCampus.TelescopeTask/dotnetCampus.TelescopeTask.csproj b/src/dotnetCampus.TelescopeTask/dotnetCampus.TelescopeTask.csproj
index 8141392..2e889a3 100644
--- a/src/dotnetCampus.TelescopeTask/dotnetCampus.TelescopeTask.csproj
+++ b/src/dotnetCampus.TelescopeTask/dotnetCampus.TelescopeTask.csproj
@@ -9,7 +9,7 @@
-
+
@@ -28,5 +28,5 @@
-
+
From 9c77b6d54f27f4fc1322f97cdf703a08d86e8b1a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E7=8E=8B=E5=B7=9E=E5=9F=8E?=
<36623158+SeWZC@users.noreply.github.com>
Date: Tue, 23 Jan 2024 15:30:01 +0800
Subject: [PATCH 2/5] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E6=96=87=E4=BB=B6?=
=?UTF-8?q?=E8=8C=83=E5=9B=B4=E5=91=BD=E5=90=8D=E7=A9=BA=E9=97=B4=E6=94=AF?=
=?UTF-8?q?=E6=8C=81?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
在语法解析中,文件范围命名空间和命名空间是不同的节点
---
src/SourceFusion.Tool/Syntax/CompileTypeVisitor.cs | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/src/SourceFusion.Tool/Syntax/CompileTypeVisitor.cs b/src/SourceFusion.Tool/Syntax/CompileTypeVisitor.cs
index 8648378..3c51dbc 100644
--- a/src/SourceFusion.Tool/Syntax/CompileTypeVisitor.cs
+++ b/src/SourceFusion.Tool/Syntax/CompileTypeVisitor.cs
@@ -87,6 +87,20 @@ public override SyntaxNode VisitNamespaceDeclaration(NamespaceDeclarationSyntax
return base.VisitNamespaceDeclaration(node);
}
+ ///
+ /// 获取文件命名空间
+ ///
+ ///
+ ///
+ public override SyntaxNode VisitFileScopedNamespaceDeclaration(FileScopedNamespaceDeclarationSyntax node)
+ {
+ var nameSyntax = Visit(node.Name);
+ // 命名空间
+ _namespace = nameSyntax.ToFullString().Trim();
+
+ return base.VisitFileScopedNamespaceDeclaration(node);
+ }
+
///
/// 获取类
///
From d63c8bda5091338fb133cb437d47feaf6b5733c4 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E7=8E=8B=E5=B7=9E=E5=9F=8E?=
<36623158+SeWZC@users.noreply.github.com>
Date: Tue, 23 Jan 2024 15:58:27 +0800
Subject: [PATCH 3/5] =?UTF-8?q?action=20=E4=BD=BF=E7=94=A8=20dotnet=20?=
=?UTF-8?q?=E7=89=88=E6=9C=AC=208.0.x=20=E8=BF=9B=E8=A1=8C=E7=BC=96?=
=?UTF-8?q?=E8=AF=91?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.github/workflows/dotnetcore.yml | 2 +-
.github/workflows/nuget publish.yml | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/.github/workflows/dotnetcore.yml b/.github/workflows/dotnetcore.yml
index 2d2c9be..e2a9349 100644
--- a/.github/workflows/dotnetcore.yml
+++ b/.github/workflows/dotnetcore.yml
@@ -13,7 +13,7 @@ jobs:
- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
- dotnet-version: '6.0.x'
+ dotnet-version: '8.0.x'
include-prerelease: true
- name: Build with dotnet
run: dotnet build --configuration Release -v n
diff --git a/.github/workflows/nuget publish.yml b/.github/workflows/nuget publish.yml
index af2c6f2..f01d921 100644
--- a/.github/workflows/nuget publish.yml
+++ b/.github/workflows/nuget publish.yml
@@ -14,7 +14,7 @@ jobs:
- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
- dotnet-version: '6.0.x'
+ dotnet-version: '8.0.x'
include-prerelease: true
- name: Install dotnet tool
From cfba527e076b56355d4a05b683466e14a0e783c5 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E7=8E=8B=E5=B7=9E=E5=9F=8E?=
<36623158+SeWZC@users.noreply.github.com>
Date: Wed, 24 Jan 2024 16:18:55 +0800
Subject: [PATCH 4/5] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E5=89=8D=E6=BB=9A?=
=?UTF-8?q?=E6=8E=A7=E5=88=B6=EF=BC=8C=E5=89=8D=E6=BB=9A=E5=88=B0=E4=B8=8B?=
=?UTF-8?q?=E4=B8=80=E4=B8=AA=E5=8F=AF=E7=94=A8=E7=9A=84=E6=9B=B4=E9=AB=98?=
=?UTF-8?q?=E4=B8=BB=E8=A6=81=E7=89=88=E6=9C=AC=E5=92=8C=E6=9C=80=E4=BD=8E?=
=?UTF-8?q?=E7=9A=84=E6=AC=A1=E8=A6=81=E7=89=88=E6=9C=AC?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
Directory.Build.props | 1 +
1 file changed, 1 insertion(+)
diff --git a/Directory.Build.props b/Directory.Build.props
index 734ffac..15d7066 100644
--- a/Directory.Build.props
+++ b/Directory.Build.props
@@ -13,6 +13,7 @@
https://github.com/dotnet-campus/SourceFusion.git
git
source;dotnet;nuget;msbuild;compile
+ Major
From e9230787a70bd0270a394fbedf7b6d2cff76283c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E7=8E=8B=E5=B7=9E=E5=9F=8E?=
<36623158+SeWZC@users.noreply.github.com>
Date: Mon, 29 Jan 2024 10:09:15 +0800
Subject: [PATCH 5/5] =?UTF-8?q?=E5=89=8D=E6=BB=9A=E6=8E=A7=E5=88=B6?=
=?UTF-8?q?=E8=AE=BE=E7=BD=AE=E5=88=B0=20=20TelescopeTask=20=E9=A1=B9?=
=?UTF-8?q?=E7=9B=AE=E8=80=8C=E4=B8=8D=E6=98=AF=20Directory.Build.props?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
Directory.Build.props | 1 -
src/dotnetCampus.TelescopeTask/dotnetCampus.TelescopeTask.csproj | 1 +
2 files changed, 1 insertion(+), 1 deletion(-)
diff --git a/Directory.Build.props b/Directory.Build.props
index 15d7066..734ffac 100644
--- a/Directory.Build.props
+++ b/Directory.Build.props
@@ -13,7 +13,6 @@
https://github.com/dotnet-campus/SourceFusion.git
git
source;dotnet;nuget;msbuild;compile
- Major
diff --git a/src/dotnetCampus.TelescopeTask/dotnetCampus.TelescopeTask.csproj b/src/dotnetCampus.TelescopeTask/dotnetCampus.TelescopeTask.csproj
index 2e889a3..fa4a480 100644
--- a/src/dotnetCampus.TelescopeTask/dotnetCampus.TelescopeTask.csproj
+++ b/src/dotnetCampus.TelescopeTask/dotnetCampus.TelescopeTask.csproj
@@ -3,6 +3,7 @@
Exe
net6.0;net5.0;netcoreapp3.1;net48
+ Major