diff --git a/bin/cli.js b/bin/cli.js index d8f14cd7..99f4db52 100755 --- a/bin/cli.js +++ b/bin/cli.js @@ -27,6 +27,7 @@ program .option('--orphans', 'show modules that no one is depending on') .option('--leaves', 'show modules that have no dependencies') .option('--dot', 'show graph using the DOT language') + .option('--rankdir ', 'set the direction of the graph layout') .option('--extensions ', 'comma separated string of valid file extensions') .option('--require-config ', 'path to RequireJS config') .option('--webpack-config ', 'path to webpack config') @@ -130,6 +131,10 @@ if (!program.color) { config.edgeColor = '#757575'; } +if (program.rankdir) { + config.rankdir = program.rankdir; +} + function dependencyFilter() { let prevFile;