{"id":13687840,"url":"https://github.com/ContextMapper/context-mapper-cli","last_synced_at":"2025-05-01T15:33:12.911Z","repository":{"id":39305550,"uuid":"301708364","full_name":"ContextMapper/context-mapper-cli","owner":"ContextMapper","description":"Context Mapper Command Line Interface (CLI)","archived":false,"fork":false,"pushed_at":"2024-02-22T16:14:30.000Z","size":112,"stargazers_count":15,"open_issues_count":1,"forks_count":3,"subscribers_count":4,"default_branch":"master","last_synced_at":"2024-08-03T15:06:49.476Z","etag":null,"topics":["cli","context-mapper","context-mapping","ddd","dsl"],"latest_commit_sha":null,"homepage":"https://contextmapper.org/","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ContextMapper.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null},"funding":{"github":"stefan-ka"}},"created_at":"2020-10-06T11:45:55.000Z","updated_at":"2024-07-29T16:39:34.000Z","dependencies_parsed_at":"2023-11-24T23:21:48.150Z","dependency_job_id":"dddef313-f480-4193-8775-7c9ab86d5e66","html_url":"https://github.com/ContextMapper/context-mapper-cli","commit_stats":null,"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ContextMapper%2Fcontext-mapper-cli","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ContextMapper%2Fcontext-mapper-cli/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ContextMapper%2Fcontext-mapper-cli/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ContextMapper%2Fcontext-mapper-cli/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ContextMapper","download_url":"https://codeload.github.com/ContextMapper/context-mapper-cli/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":224266327,"owners_count":17283111,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cli","context-mapper","context-mapping","ddd","dsl"],"created_at":"2024-08-02T15:01:01.643Z","updated_at":"2025-05-01T15:33:12.899Z","avatar_url":"https://github.com/ContextMapper.png","language":"Java","funding_links":["https://github.com/sponsors/stefan-ka"],"categories":["cli"],"sub_categories":[],"readme":"![Context Mapper](https://raw.githubusercontent.com/wiki/ContextMapper/context-mapper-dsl/logo/cm-logo-github-small.png)\n# Context Mapper CLI\n[![Build (master)](https://github.com/ContextMapper/context-mapper-cli/actions/workflows/build_master.yml/badge.svg)](https://github.com/ContextMapper/context-mapper-cli/actions) [![codecov](https://codecov.io/gh/ContextMapper/context-mapper-cli/branch/master/graph/badge.svg?token=OMqxkddZOJ)](https://codecov.io/gh/ContextMapper/context-mapper-cli) [![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0) [![Maven Central](https://img.shields.io/maven-central/v/org.contextmapper/context-mapper-cli.svg?label=Maven%20Central)](https://search.maven.org/search?q=g:%22org.contextmapper%22%20AND%20a:%22context-mapper-cli%22)\n\nThis repository contains the Context Mapper CLI - a command line interface to validate CML files and call generators\n(currently PlantUML, Context Map, and generic text files via Freemarker template).\n\n## Download\nThe CLI can be downloaded under the following links:\n * [TAR](https://repo1.maven.org/maven2/org/contextmapper/context-mapper-cli/6.12.0/context-mapper-cli-6.12.0.tar) (Linux, Mac)\n * [ZIP](https://repo1.maven.org/maven2/org/contextmapper/context-mapper-cli/6.12.0/context-mapper-cli-6.12.0.zip) (Windows)\n\nIn case you want to include Context Mapper in your Maven or Gradle build, you can use the CLI to call generators (for example with Maven exec plugin).\n\n**Gradle:**\n```gradle\nimplementation 'org.contextmapper:context-mapper-cli:6.12.0'\n```\n\n**Maven:**\n```xml\n\u003cdependency\u003e\n  \u003cgroupId\u003eorg.contextmapper\u003c/groupId\u003e\n  \u003cartifactId\u003econtext-mapper-cli\u003c/artifactId\u003e\n  \u003cversion\u003e6.12.0\u003c/version\u003e\n\u003c/dependency\u003e\n```\n\n## Validate Command Usage\n```shell\n$ ./cm validate -h\nContext Mapper CLI\nusage: cm validate\n -h,--help          Prints this message.\n -i,--input \u003carg\u003e   Path to the CML file which you want to validate.\n```\n\n## Generate Command Usage\n```shell\n$ ./cm generate -h\nContext Mapper CLI\nusage: cm generate\n -f,--outputFile \u003carg\u003e   The name of the file that shall be generated\n                         (only used by Freemarker generator, as we cannot\n                         know the file extension).\n -g,--generator \u003carg\u003e    The generator you want to call. Use one of the\n                         following values: context-map (Graphical DDD\n                         Context Map), plantuml (PlantUML class-,\n                         component-, and state diagrams.), generic\n                         (Generate generic text with Freemarker template)\n -h,--help               Prints this message.\n -i,--input \u003carg\u003e        Path to the CML file for which you want to\n                         generate output.\n -o,--outputDir \u003carg\u003e    Path to the directory into which you want to\n                         generate.\n -t,--template \u003carg\u003e     Path to the Freemarker template you want to use.\n                         This parameter is only used if you pass 'generic'\n                         to the 'generator' (-g) parameter.\n```\n\n## Usage examples\nThe following examples illustrate the CLI usage.\n\n### Validate *.cml File\n\n```shell\n./cm validate -i DDD-Sample.cml\n```\n\n### Generate PlantUML\n\n```shell\n./cm generate -i DDD-Sample.cml -g plantuml -o ./output-directory\n```\n\n### Generate Context Map\n\n```shell\n./cm generate -i DDD-Sample.cml -g context-map -o ./output-directory\n```\n\n### Generate Arbitrary Text File with Freemarker Template\n\n```shell\n./cm generate -i DDD-Sample.cml -g generic -o ./output-directory -t template.md.ftl -f glossary.md\n```\n\n## Development / Build\nIf you want to contribute to this project you can create a fork and a pull request. The project is built with Gradle, so you can import it as Gradle project within Eclipse or IntelliJ IDEA (or any other IDE supporting Gradle).\n\n## Contributing\nContribution is always welcome! Here are some ways how you can contribute:\n* Create GitHub issues if you find bugs or just want to give suggestions for improvements.\n* This is an open source project: if you want to code, [create pull requests](https://help.github.com/articles/creating-a-pull-request/) from [forks of this repository](https://help.github.com/articles/fork-a-repo/). Please refer to a Github issue if you contribute this way.\n* If you want to contribute to our documentation and user guides on our website [https://contextmapper.org/](https://contextmapper.org/), create pull requests from forks of the corresponding page repo [https://github.com/ContextMapper/contextmapper.github.io](https://github.com/ContextMapper/contextmapper.github.io) or create issues [there](https://github.com/ContextMapper/contextmapper.github.io/issues).\n\n## Licence\nContextMapper is released under the [Apache License, Version 2.0](http://www.apache.org/licenses/LICENSE-2.0).\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FContextMapper%2Fcontext-mapper-cli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FContextMapper%2Fcontext-mapper-cli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FContextMapper%2Fcontext-mapper-cli/lists"}