Created
October 30, 2010 14:00
-
-
Save alexeyr/655324 to your computer and use it in GitHub Desktop.
Revisions
-
alexeyr revised this gist
Oct 30, 2010 . 1 changed file with 3 additions and 5 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -10,9 +10,7 @@ write_to(Filename) -> A2L = fun atom_to_list/1, file:write_file(Filename, ["graph G { \n" , [[$\t, A2L(From), " -- ", A2L(To), " ; ", $\n] || {From, To} <- Mods] , " }\n"]). -
beapirate created this gist
Oct 29, 2010 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,18 @@ -module(moddeps). -compile(export_all). write_to(Filename) -> xref:start(s), xref:add_directory(s, "ebin"), {ok, Calls} = xref:q(s, "XC"), Mods = [{From, To} || {{From,_,_}, {To,_,_}} <- Calls], A2L = fun atom_to_list/1, file:write_file(Filename, iolist_to_binary( "graph G { " ++ [$\n] ++ [[$\t, A2L(From), " -- ", A2L(To), " ; ", $\n] || {From, To} <- Mods] ++ " }" ++ [$\n])).