upload supports updating files
Separate newFile and newVersin in two processes (easier to read). Not
tested yet