I'm trying to a write a plugin that simulates the existence of extra files. The most obvious way to do that seems to be overriding the methods on the CompilerHost object, and that does work for a one-shot build. However, running with --watch appears to start using the created CompilerHost long before the Program is created, so the non-existence of my virtual files has already been cached by the time the plugins run.
Would it be possible to support a new plugin type that can run early enough to transform CompilerHost?
I'm trying to a write a plugin that simulates the existence of extra files. The most obvious way to do that seems to be overriding the methods on the CompilerHost object, and that does work for a one-shot build. However, running with
--watchappears to start using the created CompilerHost long before the Program is created, so the non-existence of my virtual files has already been cached by the time the plugins run.Would it be possible to support a new plugin type that can run early enough to transform CompilerHost?