I'd like to print out the output of a "/usr/bin/tree" command.

For instance :

├── common.yaml
└── virtual
    ├── false.yaml
    └── true.yaml

My idea was to put this in a minted environment. But the fontfamily would not contain the UTF8 caracters like :

Missing character: There is no ├ in font [lmroman10-regular]:mapping=tex-text!

I tried some other fontfamilies (like dejavusansmono), but no luck with this.

Is there a fontfamily wich provides these characters ?


I used xelatex and the CMU Typewriter Text font.

These fonts are proved to work:

  • CMU Typewriter Text
  • DejaVu Sans Mono
  • Liberation Mono
  • Linux Libertine Mono O

These are proved to fail:

  • Latin Modern Mono (shows no symbol)
  • Bitstream Vera Sans Mono (shows boxes)
  • Droid Sans Mono (shows boxes)
  • Nimbus Mono L (shows no symbol)

Typeset with xelatex -shell-escape.

\pagestyle{empty}% for cropping
\setmonofont{CMU Typewriter Text}
├── common.yaml
└── virtual
    ├── false.yaml
    └── true.yaml

enter image description here

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.