mermaid-js / mermaid-cli

Command line tool for the Mermaid library
MIT License
2.23k stars 210 forks source link

Using a config file does not work #620

Closed TeaDrinkingProgrammer closed 7 months ago

TeaDrinkingProgrammer commented 7 months ago

Describe the bug The CLI does not respect the use of a config file

To Reproduce

  1. Make a repro.mmd file with the following contents:
    
    mindmap
    root((test))
    Hello world

2. Make a mmconfig.json file with the following content:

{ "theme": "dark" }


3. Execute the following command in the folder: `mmdc -i ./repro.mmd -o output.png -c ./mmconfig.json`

**Expected behavior**
Resulting image should have the configuration applied, but has a light theme instead of a dark theme

**Screenshots**
Resulting image:
![output](https://github.com/mermaid-js/mermaid-cli/assets/20358521/593af0f0-0ed2-470d-9553-873393dbd0cc)

**Desktop (please complete the following information):**

- OS: Fedora 39 KDE
- Browser N.A
- Version 10.6.1

Related to #621
TeaDrinkingProgrammer commented 7 months ago

See #621