Tasks Cheatsheet
exploration
Exploration
basic-execution
Basic execution
Run all exploration stages
$ mix arch.explore
include-dependencies
Include dependencies
Run all exploration stages on project and dependencies that match filter(s)
$ mix arch.explore --include-deps "phoenix*"
no-coverage
No coverage
Skip coverage information gathering stage
$ mix arch.explore --no-coverage
html-report
HTML Report
To be run, it's necessary you already successfully ran the exploration stage
basic-execution-1
Basic execution
Generate default HTML static report
$ mix arch.report.html
limit-query-results
Limit Query Results
Limit the number of results of the queries used in the report (e.g. to 10 elements)
$ mix arch.report.html --limit 10
analysis-common-options
Analysis Common Options
Option | Default | Supported by |
---|---|---|
--format | Depends on task | apps.xref, dsm, treemap, xref |
--out | console | apps.xref, dsm, treemap, xref |
--app | * (All applications) | dsm, treemap, xref |
--ns | * (All modules) | dsm, treemap, xref |
--db | archeometer_<project name>.db | dsm, treemap, xref |
--skip-tests | true | dsm, treemap |
A more complex example using this options. This will generate a DSM from a database that is not the defaultone and consider only modules that belong to foo application in the namespace Foo.Bar and not ignoring the test modules.
$ mix arch.dsm \
--out foo.bar.svg \
--format svg \
--app foo \
--ns Foo.Bar \
--skip-tests false \
--db archeometer_wareware.db
analysis
Analysis
apps-xref
Apps XRef
Basic execution
Print the dependency graph of applications in console (as text)
$ mix arch.apps.xref
Format
Following formats are supported
- dot (default)
- png
- svg
Include dependencies
Target project and include dependencies that match the filter(s)
This option can be used on non-Umbrella projects
$ mix arch.apps.xref --include-deps "phoenix*"
xref
XRef
Basic execution
Generate a dependency graph between given modules and print it to console
$ mix arch.xref mod1 mod2 .. modN
Format
Following formats are supported
- dot (default)
- png
- svg
design-structure-matrix-dsm
Design Structure Matrix (DSM)
Basic Execution
Generate a DSM of all non-test modules and print it to console
$ mix arch.dsm
Format
Following formats are supported
- txt
- svg
treemap
Treemap
Basic Execution
Generate a Treemap of all non-test modules from the project and print it to console
$ mix arch.treemap
Metric
For now only size metric is supported
$ mix arch.treemap --metric size
exploration-subtasks
Exploration Subtasks
include-dependencies-1
Include Dependencies
Just as in the main Explore task you can include dependencies (not supported by arch.explore.coverage)
$ mix arch.explore.static --include deps "phoenix*"
explore-static
Explore Static
Target project ex
files but not dependencies
$ mix arch.explore.static
explore-xrefs
Explore XRefs
Save information of dependencies between project modules
$ mix arch.explore.xrefs
explore-apps
Explore Apps
Save applications names, modules implemented behaviours and structs from project
$ mix arch.explore.apps
explore-ecto
Explore Ecto
Save information of Ecto schema modules and their relationships
$ mix arch.explore.ecto
explore-coverage
Explore Coverage
Run project tests files and save coverage information
$ mix arch.explore.coverage