22

Recently I started writing some doxygen docs in an existing project which already has quite a lot of doxygen comments.

Since I'm learning a bit - I like to iterate with making edits and generating docs, since doc generation is quite slow - 3-5min. This becomes un-workable.

I managed by deleting most of the files in the source tree so doxy only found the ones I was editing but this is really a horrible solution and not something I'd want to do frequently.

Is there a way (command line arg or env variable for eg) - to limit which files/modules are used for generating docs - so rebuilding docs can be done much faster?

ideasman42
  • 42,413
  • 44
  • 197
  • 320
  • 1
    You can just pass a single file as the argument to `INPUT` in the doxygen configuration file. See also the answers in the thread http://stackoverflow.com/questions/203172/how-to-get-doxygen-to-run-faster – Chris Feb 28 '12 at 15:43

1 Answers1

28

Yes, you can customize Doxygen's behavior from either the command-line or via environment variables. For example, if you only want to include one file (include/somefile.h), you could execute Doxygen like:

( cat Doxyfile ; echo "INPUT=include/somefile.h" ) | doxygen -

see the Doxygen FAQ's "Can I configure doxygen from the command line?" for more details on customizing behavior from the command line.

Alternatively, if you want to use environment variables, you could use specify something like the following in your configuration file:

INPUT = $(FILE)

Doxygen performs environment variable substitution on its configuration files, allowing you to specify which file(s) should be acted on using:

export FILE=include/somefile.h
doxygen Doxyfile

See Doxygen Configuration for details on using environment variables in configuration files.

albert
  • 8,285
  • 3
  • 19
  • 32
DRH
  • 7,868
  • 35
  • 42