Skip to content

Commit dd726bb

Browse files
authored
chore: rename Projgraph lib and prepare nuget to be push (#60)
1 parent 7f5d3c3 commit dd726bb

45 files changed

Lines changed: 698 additions & 78 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

ARCHITECTURE.md

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -7,31 +7,31 @@ exposes two entry points — a CLI and an MCP server — both backed by a shared
77

88
## Solution Structure
99

10-
```none
10+
```sh
1111
ProjGraph.slnx
1212
├── src/
13-
│ ├── ProjGraph.Cli # Spectre.Console CLI entry point
14-
│ ├── ProjGraph.Mcp # MCP server entry point (JSON-RPC over stdio)
15-
│ ├── ProjGraph.Lib # Composition root — wires all sub-libraries via DI
16-
│ ├── ProjGraph.Lib.Core # Shared abstractions, parsers, infrastructure
17-
│ ├── ProjGraph.Lib.ProjectGraph # Solution/project dependency graph analysis
18-
│ ├── ProjGraph.Lib.ClassDiagram # C# class hierarchy analysis (Roslyn)
19-
│ ├── ProjGraph.Lib.EntityFramework # EF Core DbContext/ModelSnapshot ERD analysis
20-
│ └── ProjGraph.Core # Shared domain models (SolutionGraph, ClassModel, EfModel)
13+
│ ├── ProjGraph.Cli # Spectre.Console CLI entry point
14+
│ ├── ProjGraph.Mcp # MCP server entry point (JSON-RPC over stdio)
15+
│ ├── ProjGraph.Lib # Composition root — wires all sub-libraries via DI
16+
│ ├── ProjGraph.Lib.Core # Shared abstractions, parsers, infrastructure
17+
│ ├── ProjGraph.Lib.Dependencies # Solution/project dependency graph analysis
18+
│ ├── ProjGraph.Lib.ClassDiagram # C# class hierarchy analysis (Roslyn)
19+
│ ├── ProjGraph.Lib.EntityFramework # EF Core DbContext/ModelSnapshot ERD analysis
20+
│ └── ProjGraph.Core # Shared domain models (SolutionGraph, ClassModel, EfModel)
2121
├── tests/
22-
│ ├── ProjGraph.Tests.Unit.* # Unit tests per library
23-
│ ├── ProjGraph.Tests.Integration.* # Integration tests for CLI and MCP
24-
│ ├── ProjGraph.Tests.Contract # MCP contract & DI wiring tests
25-
│ └── ProjGraph.Tests.Shared # Shared test helpers
26-
└── samples/ # Sample projects used by integration tests
22+
│ ├── ProjGraph.Tests.Unit.* # Unit tests per library
23+
│ ├── ProjGraph.Tests.Integration.* # Integration tests for CLI and MCP
24+
│ ├── ProjGraph.Tests.Contract # MCP contract & DI wiring tests
25+
│ └── ProjGraph.Tests.Shared # Shared test helpers
26+
└── samples/ # Sample projects used by integration tests
2727
```
2828

2929
## Dependency Graph
3030

31-
```none
31+
```sh
3232
Cli ──┐
3333
├──► Lib ──► Lib.Core ──► Core
34-
Mcp ──┘ ├──► Lib.ProjectGraph ──► Lib.Core
34+
Mcp ──┘ ├──► Lib.Dependencies ──► Lib.Core
3535
├──► Lib.ClassDiagram ──► Lib.Core
3636
└──► Lib.EntityFramework ──► Lib.Core
3737
```
@@ -111,7 +111,7 @@ Releases are triggered by pushing a `v*` Git tag and are fully automated via `.g
111111

112112
### Release Flow
113113

114-
```none
114+
```sh
115115
Tag push (v*)
116116
117117
├── Update version in Directory.Build.props & server.json
@@ -131,7 +131,7 @@ The Official MCP Registry verifies package ownership before accepting a submissi
131131
README for a hidden HTML comment:
132132

133133
```html
134-
<!-- mcp-name: io.github.handys11/projgraph -->
134+
<!-- mcp-name: io.github.HandyS11/projgraph -->
135135
```
136136

137137
This comment must be present at the end of `src/ProjGraph.Mcp/README.md`. The identifier in the comment must exactly

ProjGraph.slnx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
<Project Path="src/ProjGraph.Lib.ClassDiagram/ProjGraph.Lib.ClassDiagram.csproj"/>
3535
<Project Path="src/ProjGraph.Lib.Core/ProjGraph.Lib.Core.csproj"/>
3636
<Project Path="src/ProjGraph.Lib.EntityFramework/ProjGraph.Lib.EntityFramework.csproj"/>
37-
<Project Path="src/ProjGraph.Lib.ProjectGraph/ProjGraph.Lib.ProjectGraph.csproj"/>
37+
<Project Path="src/ProjGraph.Lib.Dependencies/ProjGraph.Lib.Dependencies.csproj"/>
3838
<Project Path="src/ProjGraph.Lib/ProjGraph.Lib.csproj"/>
3939
<Project Path="src/ProjGraph.Cli/ProjGraph.Cli.csproj"/>
4040
<Project Path="src/ProjGraph.Mcp/ProjGraph.Mcp.csproj"/>
@@ -47,6 +47,6 @@
4747
<Project Path="tests/ProjGraph.Tests.Unit.ClassDiagram/ProjGraph.Tests.Unit.ClassDiagram.csproj"/>
4848
<Project Path="tests/ProjGraph.Tests.Unit.Core/ProjGraph.Tests.Unit.Core.csproj"/>
4949
<Project Path="tests/ProjGraph.Tests.Unit.EntityFramework/ProjGraph.Tests.Unit.EntityFramework.csproj"/>
50-
<Project Path="tests/ProjGraph.Tests.Unit.ProjectGraph/ProjGraph.Tests.Unit.ProjectGraph.csproj"/>
50+
<Project Path="tests/ProjGraph.Tests.Unit.Dependencies/ProjGraph.Tests.Unit.Dependencies.csproj"/>
5151
</Folder>
5252
</Solution>

docfx/dev/toc.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,17 @@
99
href: ../../SECURITY.md
1010
- name: 📜 License
1111
href: ../license.md
12+
13+
- name: 📦 Libraries
14+
- name: ProjGraph.Lib
15+
href: ../../src/ProjGraph.Lib/README.md
16+
- name: ProjGraph.Core
17+
href: ../../src/ProjGraph.Core/README.md
18+
- name: ProjGraph.Lib.Core
19+
href: ../../src/ProjGraph.Lib.Core/README.md
20+
- name: ProjGraph.Lib.Dependencies
21+
href: ../../src/ProjGraph.Lib.Dependencies/README.md
22+
- name: ProjGraph.Lib.ClassDiagram
23+
href: ../../src/ProjGraph.Lib.ClassDiagram/README.md
24+
- name: ProjGraph.Lib.EntityFramework
25+
href: ../../src/ProjGraph.Lib.EntityFramework/README.md

docfx/docfx.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,12 @@
4040
"SECURITY.md",
4141
"src/ProjGraph.Cli/README.md",
4242
"src/ProjGraph.Mcp/README.md",
43+
"src/ProjGraph.Lib/README.md",
44+
"src/ProjGraph.Lib.Core/README.md",
45+
"src/ProjGraph.Lib.ClassDiagram/README.md",
46+
"src/ProjGraph.Lib.EntityFramework/README.md",
47+
"src/ProjGraph.Lib.Dependencies/README.md",
48+
"src/ProjGraph.Core/README.md",
4349
"samples/**/*.md",
4450
"specs/**/*.md"
4551
]

src/ProjGraph.Cli/Commands/StatsCommand.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
using ProjGraph.Lib.Core.Abstractions;
22
using ProjGraph.Lib.Core.Infrastructure;
3-
using ProjGraph.Lib.ProjectGraph.Application;
3+
using ProjGraph.Lib.Dependencies.Application;
44
using Spectre.Console;
55
using Spectre.Console.Cli;
66
using System.ComponentModel;

src/ProjGraph.Cli/Commands/VisualizeCommand.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
using ProjGraph.Cli.Infrastructure;
22
using ProjGraph.Core.Models;
33
using ProjGraph.Lib.Core.Abstractions;
4-
using ProjGraph.Lib.ProjectGraph.Application;
4+
using ProjGraph.Lib.Dependencies.Application;
55
using Spectre.Console;
66
using Spectre.Console.Cli;
77
using System.ComponentModel;

src/ProjGraph.Cli/README.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@
33
Command-line tool for visualizing .NET project dependencies, generating Entity Relationship Diagrams, visualizing
44
class hierarchies, and computing key solution metrics.
55

6+
[![NuGet](https://img.shields.io/nuget/v/ProjGraph.Cli)](https://www.nuget.org/packages/ProjGraph.Cli)
7+
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
8+
69
## Installation
710

811
```bash
@@ -170,7 +173,7 @@ projgraph stats ./src/MyApp/MyApp.csproj
170173

171174
**Example output**:
172175

173-
```
176+
```sh
174177
────────────── MySolution ──────────────
175178
Total projects 12
176179
Libraries 7
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,20 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

3+
<PropertyGroup>
4+
<!-- Package metadata -->
5+
<IsPackable>true</IsPackable>
6+
<PackageId>ProjGraph.Core</PackageId>
7+
<Title>ProjGraph Core</Title>
8+
<PackageIcon>icon.png</PackageIcon>
9+
<Description>Core domain models, exceptions, and shared abstractions for the ProjGraph ecosystem.</Description>
10+
<PackageTags>graph;dependencies;models;core;dotnet</PackageTags>
11+
<PackageReadmeFile>README.md</PackageReadmeFile>
12+
</PropertyGroup>
13+
14+
<!-- Include README and icon in package -->
15+
<ItemGroup>
16+
<None Include="README.md" Pack="true" PackagePath="/"/>
17+
<None Include="..\..\icon.png" Pack="true" PackagePath=""/>
18+
</ItemGroup>
19+
320
</Project>

src/ProjGraph.Core/README.md

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
# ProjGraph.Core
2+
3+
Core domain models, exceptions, and shared abstractions for the ProjGraph ecosystem.
4+
5+
[![NuGet](https://img.shields.io/nuget/v/ProjGraph.Core)](https://www.nuget.org/packages/ProjGraph.Core)
6+
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
7+
8+
## Installation
9+
10+
```bash
11+
dotnet add package ProjGraph.Core
12+
```
13+
14+
## Overview
15+
16+
`ProjGraph.Core` is the foundational package for the ProjGraph ecosystem. It provides the shared domain models,
17+
enumerations, and exception types consumed by all higher-level ProjGraph libraries.
18+
19+
This package is typically not referenced directly — prefer one of the higher-level packages:
20+
21+
- [`ProjGraph.Lib.Dependencies`](https://www.nuget.org/packages/ProjGraph.Lib.Dependencies) — project dependency graph
22+
- [`ProjGraph.Lib.ClassDiagram`](https://www.nuget.org/packages/ProjGraph.Lib.ClassDiagram) — class hierarchy analysis
23+
- [`ProjGraph.Lib.EntityFramework`](https://www.nuget.org/packages/ProjGraph.Lib.EntityFramework) — EF Core ERD
24+
generation
25+
- [`ProjGraph.Lib`](https://www.nuget.org/packages/ProjGraph.Lib) — meta-package (all of the above)
26+
27+
## Models
28+
29+
| Type | Description |
30+
|--------------------|-------------------------------------------------------------------|
31+
| `Project` | Represents a .NET project or package node in the dependency graph |
32+
| `Dependency` | Represents a directed edge between two `Project` nodes |
33+
| `DependencyType` | Enum: `ProjectReference`, `PackageReference` |
34+
| `ProjectType` | Enum: `Project`, `Package` |
35+
| `ClassModel` | Roslyn-derived class/record/interface descriptor |
36+
| `MemberDefinition` | Field, property, or method descriptor within a `ClassModel` |
37+
| `EfModel` | Entity Framework database model |
38+
| `EfEntity` | Table/entity within an EF model |
39+
| `EfProperty` | Column/property on an `EfEntity` |
40+
| `EfRelationship` | Foreign-key relationship between two entities |
41+
42+
## Exceptions
43+
44+
| Type | Description |
45+
|----------------------|------------------------------------------------------------------|
46+
| `ProjGraphException` | Base exception for all ProjGraph errors |
47+
| `ParsingException` | Thrown when a solution, project, or source file cannot be parsed |
48+
| `AnalysisException` | Thrown when Roslyn or EF analysis fails |
49+
50+
## Links
51+
52+
- [GitHub Repository](https://github.com/HandyS11/ProjGraph)
53+
- [Documentation](https://handys11.github.io/ProjGraph)

src/ProjGraph.Lib.ClassDiagram/ProjGraph.Lib.ClassDiagram.csproj

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,22 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

3+
<PropertyGroup>
4+
<!-- Package metadata -->
5+
<IsPackable>true</IsPackable>
6+
<PackageId>ProjGraph.Lib.ClassDiagram</PackageId>
7+
<Title>ProjGraph Library Class Diagram</Title>
8+
<PackageIcon>icon.png</PackageIcon>
9+
<Description>Roslyn-powered class hierarchy analysis and Mermaid class diagram generation for .NET projects.</Description>
10+
<PackageTags>graph;classdiagram;roslyn;mermaid;visualization;dotnet</PackageTags>
11+
<PackageReadmeFile>README.md</PackageReadmeFile>
12+
</PropertyGroup>
13+
14+
<!-- Include README and icon in package -->
15+
<ItemGroup>
16+
<None Include="README.md" Pack="true" PackagePath="/"/>
17+
<None Include="..\..\icon.png" Pack="true" PackagePath=""/>
18+
</ItemGroup>
19+
320
<ItemGroup>
421
<ProjectReference Include="..\ProjGraph.Lib.Core\ProjGraph.Lib.Core.csproj"/>
522
</ItemGroup>

0 commit comments

Comments
 (0)