Improve FileSync for file copy
Take asynchronous compilation execution into account