sofname
sofname

Reputation: 441

Graphviz: use environment variables in hyperlinks

The following dot file contains a hyperlink pointing to a local text file.

digraph d {
    A [href="/home/test/test.txt"]
    A -> B
    A -> C
}

Suppose an environment variable, HOME_TEST, has the value "/home/test". Is it possible to use the environment variable in the dot file instead of the hard coding?

Upvotes: 0

Views: 113

Answers (1)

tink
tink

Reputation: 15206

Short answer:

No. dot has no mechanism to do that.

Longer (very generic) answer:

You can use something like make in conjunction with m4 or another macro-processor to do what you want/need.

Upvotes: 1

Related Questions