Fixes #439, run onBuildRead/Write on files if skipDirOptimize is false