The manual for the 'graphics' LaTeX bundle includes instructions for setting up the right conditions for the use of colour and the inclusion of graphics in documents.

For example, on page 2, it says

You should to set up a site default for these options, for the driver that you normally use. Suppose that you wish for the color package to always default to use specials for the PostScript driver, dvipsone. In that case create a file color.cfg containing the line:


Normally you will want an identical file graphics.cfg to set a similar default for the graphics packages.

I therefore have color.cfg and graphics.cfg set up in the personal TEXMF tree.

This is something of a pain, however. If I need to compile cleanly, I put TEXMFHOME=/non-existent-directory precisely so that these configuration files are not loaded. In this case, the standard TeX Live versions will be picked up.

So I could, I think, just drop these files from my home directory altogether. However, they are useful for some purposes e.g. for additions to the standard configuration.

What is the best way to handle this? Is there a way of including the standard configuration files from within the personalised ones? Clearly I could \input them by specifying a full path, but I'm not sure whether that's the right thing to do here.

  • 1
    I'd just not have the local ones, it makes a hidden dependency that makes your documents non-portable. – David Carlisle Mar 30 '15 at 17:54
  • @DavidCarlisle To be honest, I don't worry about portability. Whatever I send elsewhere has to be converted to Word anyway. If I knew even one person who'd take .tex, things would be different ;). – cfr Mar 30 '15 at 18:41

I wrote that a long time ago, before texlive, before tetex probably. The model for the initial releases of latex2e (and graphics) was that individual users would be fetching source files of individual directories from ctan and building a tex setup themselves. (And that the core distribution wouldn't have a cfg file so you'd have to write your own if you wanted one at all.)

These days the graphics.cfg file (and color.cfg) is really an integral part of the tex distribution (whether that is miktex or texlive or something else) and the behaviour of the standard one is just assumed. (Witness how many answers here tell people to avoid specifying driver options to the package so an appropriate driver option will be chosen).

So, it is possible to have a local version, but it's possible to have a local copy of graphics.sty or even latex.ltx but I would treat these the same way, and only make such modified copies in very special circumstances, and ignore the advice that the .cfg file should be written to fit local needs.

| improve this answer | |
  • Thanks! What about color.cfg? Right now, I guess I'm doing this in some other way, having disabled my copy of this. But it would be useful to be able to define custom colours so they are available whenever colour is used. – cfr Nov 15 '16 at 23:31
  • @cfr same applies really. (The standard color and graphics config are the same really, just detecting pdftex or luatex etc) – David Carlisle Nov 16 '16 at 8:03
  • OK. Thanks. That's a shame, but so it goes. – cfr Nov 16 '16 at 16:01
  • @cfr Joseph has suggested in chat that an answer from a package author saying to ignore the manual might be a hint that the manual needs updating. I'll see what I can do. – David Carlisle Nov 16 '16 at 16:08

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.