twitter/commons — pull request #266 by jsirois (2014-03-24 18:15:32+00:00)
Title: Have scrooge gen isolate outputs per-target.

Using a temporary output dir and linking products and filemaps
to per-target directories allows for several targets to own
variants of the same file. As long as those targets are never
compiled together, then their scrooge products will not trample
each other.

Guarding against multiple versions of the same thrift file being
passed to scrooge in one round would require either introspecting
the namespace and struct/enum/constant/service names or else
adding an option to scrooge to have it fail-fast when handed
files that collide.

This change also cleans up ScroogeGen in minor ways, eliminating
un-needed relpath wrapping and a custom _tempname impl and
re-naming private helpers with leading underscores for clarity.

https://rbcommons.com/s/twitter/r/140/