Fixed file rename issues on Linux