Behold Fortranpack: A Modern Fortran Numerical & Scientific Programming Package
What is this you ask? It’s just an FPM manifest that imports all my other libraries! So, add it as a dependency and you get everything.
Genius or cursed?
It’s just an experiment really. I was wondering if there would be some utility in a meta-library like this. Rather than having everything in a single repository (like stdlib), things are split up and development separately. Something to think about. There are pros and cons to both approaches.
Super-packages are interesting and educational as github, fpm, and compilers all get exercised differently than when working piecemeal with smaller projects.
I have been using a slightly different approach, partly for testing fpm, since the inception of the Fortran branch of fpm.
As you mentioned, there are pros and cons to each approach, but I was expecting an fpm repository to have developed more than has occurred, which tends to favor smaller packages. Theoretically the repository seemed like it would be a natural hotbed for developing stdlib modules as well.
Combining many modules gives fpm a good workout as well. Do you see any unexpected recompilations when you change a program in app/ or test/ or example/ ?
Fortranpack already has an index to all the dependencies but I did not realize till now that the output from the "--mermaid md" option can be used as-is in github markdown. I think I will spend a bit of time adding the dependency graphs to my README.md files.
Fortranpack is not only a good way to exercise fpm but a decent test of a Fortran compiler as well
Yes, it is part of both Github- and Gitlab-flavored markdown. I’m assuming the boxes are only clickable when included in the HTML, but I may be wrong. There is also a hover effect which displays the name. In principle one can also edit line styles, shapes, or add icons and images (Flowcharts Syntax | Mermaid).
It is clickable, the hover works, and a navigator allows zooming and panning. At the bottom of the README.md
I corrected it but the original output using
fpm deps --mermaid md --output deps.md
deps.md
the top link goes to the top of repositories instead of to the prep project, although it works as expected on other projects.
It might be nice if fpm-devs wrote other github markdown formats as well, like the index in Fortranpack. The graphs are great, but the table like Fortranpack has and a simple text listing for terminal output when using fpm as well would be useful. @jacobwilliams – is your index manually generated or automated?
I haven’t really advertised it yet, but I also made text command fpm-tree (it is part of fpm-deps). For instance for fortranpack, it currently display the following:
Nice, thanks. Apart from FPM and fpm-tree, is there a tool that creates such a diagram for a program, showing the modules USEd by the main program and by each module?