Code Monkey home page Code Monkey logo

dependency-analyser's Introduction

.NET Dependency Analyser

Shows the dependencies between .NET projects and assemblies as a graph.

How it works

Run the application, and open a .NET assembly, project or solution from the File|Open... menu (or just press Ctrl+O).

Let's see how it looks if we run the application on itself:

Example screenshot from .NET Assembly Dependency Analyser graph

As you can see there is a lot of information here and the graph is impossible to read as-is. It's possible to zoom and pan, and you can drag nodes around to make things easier to see, but most of the time you'll want to hide assemblies you're not interested in.

Using the Filter... command lets us exclude items we don't want to see. Removing several System.*and other framework assemblies gives a clearer picture:

A graph showing dependencies when most of the behind-the-scenes assemblies have been removed

You can open either assemblies or MSBuild project/solution files. The latter produces richer data, including target frameworks which can be useful for multi-targeting projects.

Simplify

The simplify button removes any "redundant" edges from the graph. For example if we started with:

flowchart LR
   A --> B
   A --> C
   B --> C
Loading

The dependency between A and C is shown two ways here. Both directly and indirectly (via B). The simplify function removes any direct reference which is also made indirectly, which can clean up the graph considerably. Our example would then become:

flowchart LR
   A --> B
   B --> C
Loading

Mermaid support

The File menu has an option to copy the diagram using the mermaid syntax, which is supported on GitHub.

Our example from above would be:

flowchart TD
    DependencyAnalyser --> Microsoft.Msagl.WpfGraphControl
    DependencyAnalyser --> AutomaticGraphLayout.Drawing
    DependencyAnalyser --> Microsoft.Build.Locator
    DependencyAnalyser --> Microsoft.CodeAnalysis.Workspaces
    DependencyAnalyser --> Microsoft.CodeAnalysis.Workspaces.MSBuild
    Microsoft.Msagl.WpfGraphControl --> AutomaticGraphLayout.Drawing
    Microsoft.Msagl.WpfGraphControl --> AutomaticGraphLayout
    AutomaticGraphLayout.Drawing --> AutomaticGraphLayout
    Microsoft.CodeAnalysis.Workspaces --> Microsoft.CodeAnalysis
    Microsoft.CodeAnalysis.Workspaces.MSBuild --> Microsoft.Build
    Microsoft.CodeAnalysis.Workspaces.MSBuild --> Microsoft.CodeAnalysis
    Microsoft.CodeAnalysis.Workspaces.MSBuild --> Microsoft.Build.Framework
    Microsoft.CodeAnalysis.Workspaces.MSBuild --> Microsoft.CodeAnalysis.Workspaces
Loading

Installation

  1. Download zipped binaries on the releases page and extract to a folder on your PC.
  2. Run DependencyAnalyser.exe to start the program.

dependency-analyser's People

Contributors

drewnoakes avatar jeremysimmons avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.