Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save aagnone3/6be4d06987b3426017be8ea4eba7dbca to your computer and use it in GitHub Desktop.
Save aagnone3/6be4d06987b3426017be8ea4eba7dbca to your computer and use it in GitHub Desktop.
# the "graph.png" target specifies "graph.dot" as a dependency
# when "graph.png" is invoked, it invokes "graph.dot" only if necessary
graph.png: graph.dot
dot graph.dot -Tpng > graph.png
# the "graph.dot" target specifies "make_graph.py" as a dependency
# so, this command is only re-run when...
# 1) make_graph.py changes
# 2) graph.dot is not present
graph.dot: make_graph.py
python make_graph.py
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment