A somewhat easier way to generate a DGML Dependency Graph of your Business Central extensions

You might have read my post “Visualize app.json dependencies in VSCode (using GraphViz)” where I explained “another” way to generate a dependency graph. Another than what? Well – other than the DGML that was just announced on Microsoft’s Launch Event of Business Central 2020 Wave 2 as being “on the drawing board”.

Well – today Stefano Demiliani found out that the first bits are already on our system. He did that in his blogpost: “Dynamics 365 Business Central: creating a DGML dependency graph for your extensions“, for which I don’t really have anything to add.

Except for one little thing…

I don’t think a lot of people are that familiar with running the alc.exe .. or handling any of its parameters just from the top of their heads. So I decided to dive a bit in TypeScript again to make that part a bit easier for you.

And the “CRS: Compile DGML” command was born as part of the “waldo’s CRS AL Language Extension“:

The function will:
1) Find your working directory
2) Find the alc.exe
3) Find out the symbol path from your settings
And run the command that needs to run to generate the DGML of your current project.

This is obviously an alpha version.. and I’m pretty sure it will never become a beta as I expect Microsoft to come with their own command or settings (if not yet already).

But for now .. Enjoy 😉

5.00 avg. rating (98% score) - 2 votes

Permanent link to this article: https://www.waldo.be/2021/05/11/a-somewhat-easier-way-to-generate-a-dgml-dependency-graph-of-your-business-central-extensions/

3 comments

    • Guido Robben on May 11, 2021 at 9:06 am
    • Reply

    error AL1018: Directory ‘c:\Git\BouwVision’ could not be found
    error AL1018: Directory ‘c:\Git\BouwVision’ could not be found
    error AL1001: Source file ‘c:\Git\BouwVision\app.json’ could not be found
    error AL1049: A project without a manifest must have the /out option specified.

    Folder should be C:\Git\BouwVision ERP\BouwVision ERP 18. How does it determine root folder?

      • Guido Robben on May 11, 2021 at 9:07 am

      PS C:\Git\BouwVision ERP\BouwVision ERP 18\BouwVision> C:\Users\g.robben\.vscode\extensions\ms-dynamics-smb.al-7.1.453917\bin\alc.exe /project:c:\Git\BouwVision ERP\BouwVision ERP 18\BouwVision /packagecachepath:c:\Git\BouwVision ERP\BouwVision ERP 18\BouwVision./.alpackages /generatecrossreferences

      • waldo on May 11, 2021 at 9:21 am
        Author

      It’s better to open issues here:
      https://github.com/waldo1001/crs-al-language-extension/issues

      It gets the WorkspaceRootFolder from the Active Document (especially in a multiroot workspace). So, you need to have a workspace for a compileable app open (not “just” a folder with multiple apps).

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.