# Export Chocolatey source

**URL:** <https://forum.graphviz.org/t/export-chocolatey-source/663>\
**Category:** Dev\
**Created:** [May 18, 2021, 7:39am UTC](https://forum.graphviz.org/t/export-chocolatey-source/663 "2021-05-18T07:39:38Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![marc\_poisson](https://sea2.discourse-cdn.com/graphviz/user_avatar/forum.graphviz.org/marc_poisson/32/376_2.png) [@marc\_poisson](https://forum.graphviz.org/u/marc_poisson)\
**Post date:** [May 18, 2021, 7:39am UTC](https://forum.graphviz.org/t/export-chocolatey-source/663/1 "2021-05-18T07:39:38Z")

</div>

I’m looking for a way to create a GraphViz export from a Chocolatey source.  
The goal would be to see all the Chocolatey packages from this source and the associated dependencies.  
Thank you in advance for your help.

---

<div class="post-metadata">

**Author:** ![mark](https://sea2.discourse-cdn.com/graphviz/user_avatar/forum.graphviz.org/mark/32/84_2.png) [@mark](https://forum.graphviz.org/u/mark)\
**Post date:** [May 18, 2021, 8:13am UTC](https://forum.graphviz.org/t/export-chocolatey-source/663/2 "2021-05-18T08:13:44Z")

</div>

Could you give an example? I guess by Chocolatey you mean [https://chocolatey.org/](https://chocolatey.org/) – do you mean a graph of what Chocolatey packages depend on a Chocolatey package?

Are you after something like [https://graphviz.org/Gallery/directed/go-package.html](https://graphviz.org/Gallery/directed/go-package.html) ?

---

<div class="post-metadata">

**Author:** ![marc\_poisson](https://sea2.discourse-cdn.com/graphviz/user_avatar/forum.graphviz.org/marc_poisson/32/376_2.png) [@marc\_poisson](https://forum.graphviz.org/u/marc_poisson)\
**Post date:** [May 18, 2021, 8:25am UTC](https://forum.graphviz.org/t/export-chocolatey-source/663/3 "2021-05-18T08:25:24Z")

</div>

For example (for a source Chocolatey with only notepadplusplus and vcredist-all packages):

digraph G {  
rankdir=LR;  
fontname=“sans-serif”;  
fillcolor=“blues4”;  
color=“blues4”;  
fontcolor=“blues3”;  
penwidth=“0.1”;  
edge [comment=“Wildcard edge”,  
fontname=“sans-serif”,  
fontsize=10,  
colorscheme=“blues3”,  
color=2,  
fontcolor=3];  
node [fontname=“serif”,  
fontsize=13,  
fillcolor=“2”,  
colorscheme=“blues4”,  
color=“2”,  
fontcolor=“4”,  
style=“filled”];  
“notepadplusplus” → “notepadplusplus.install”  
“vcredist-all” → “vcredist2005”;  
“vcredist-all” → “vcredist2008”;  
“vcredist-all” → “vcredist2010”;  
“vcredist-all” → “vcredist2012”;  
“vcredist-all” → “vcredist2013”;  
“vcredist-all” → “vcredist140”;  
“vcredist-all” → “vcredist2015”;  
“vcredist-all” → “vcredist2017”;  
“vcredist140” → “chocolatey-core.extension”;  
“vcredist140” → “KB3033929”;  
“vcredist140” → “KB2919355”;  
“vcredist140” → “kb2999226”;  
}

---

<div class="post-metadata">

**Author:** ![mark](https://sea2.discourse-cdn.com/graphviz/user_avatar/forum.graphviz.org/mark/32/84_2.png) [@mark](https://forum.graphviz.org/u/mark)\
**Post date:** [May 18, 2021, 8:37am UTC](https://forum.graphviz.org/t/export-chocolatey-source/663/4 "2021-05-18T08:37:54Z")

</div>

OK. Looks good to me. What do you need help with in particular?

---

<div class="post-metadata">

**Author:** ![marc\_poisson](https://sea2.discourse-cdn.com/graphviz/user_avatar/forum.graphviz.org/marc_poisson/32/376_2.png) [@marc\_poisson](https://forum.graphviz.org/u/marc_poisson)\
**Post date:** [May 18, 2021, 8:47am UTC](https://forum.graphviz.org/t/export-chocolatey-source/663/5 "2021-05-18T08:47:32Z")

</div>

I wrote this file by hand.  
I want to be able to generate the file via a script (powershell for example) to which I will pass an url from a Chocolatey source (internal): chocolatey2graphviz.ps1 -source “[http://mychocolatey/chocolatey](http://mychocolatey/chocolatey)”  
This script would list all the source packages (and associated dependencies) and export a dot file (in stdout by default, or in a file passed as a parameter: -out fileexport.dot).  
Thank you in advance.
