npm
The CodeCharta Shell (CCSH) is published on npm, so you can install it globally and run analyses straight from your terminal.
Prerequisites
Section titled “Prerequisites”- Node >= 20
- Java >= 11
Install the CodeCharta Shell
Section titled “Install the CodeCharta Shell”Install the codecharta-analysis package globally and verify the installation:
# Install the CodeCharta Shell globallynpm install -g codecharta-analysis
# Verify the installation (some terminals need to be restarted first)ccsh -hAnalyze a project with CCSH
Section titled “Analyze a project with CCSH”Generate your first map
Section titled “Generate your first map”Every parser and importer produces its own metrics — see CodeCharta Shell for an overview of the available tools. In this example we use the Unified Parser, as it works on nearly every codebase:
# -o output file name# <path> the project or file you want to analyzeccsh unifiedparser -o=tutorial <path/to/your/project>This generates a tutorial.cc.json.gz, ready to be opened in the Web Studio.
Other ways to run CCSH
Section titled “Other ways to run CCSH”If you are not sure which tool to use, run the shell in interactive mode — it suggests applicable parsers for a given path and guides you through the configuration:
# guided, interactive analysisccsh -iYou can also call any tool directly — for example an importer:
ccsh csvimport example.csv -o=exampleSee CodeCharta Shell for interactive mode, parser suggestions, combining multiple metrics, and more.
Open your map in the Web Studio
Section titled “Open your map in the Web Studio”Open the Web Studio and load your tutorial.cc.json.gz with the folder-open button (Load cc.json files) in the top-left — see Upload for details. You can now explore your codebase to your heart’s content.