• Marc Cornellà's avatar
    fix(extract): fix conflict if compressed file has a folder of the same name · 49d34d00
    Marc Cornellà authored
    This change fixes the case where the compressed file (e.g. tools.tgz) only
    contains a folder with the same name (e.g. tools) in its root folder.
    
    tools.tgz:
    |- tools
       |- fileA.txt
       |- fileB.txt
       \- fileC.txt
    
    In that case, the "smart" folder creation mechanism will extract the files in
    a folder "tools", and this extraction folder will contain a single folder with
    the same name.
    
    Before this fix, the tool would try to move out the inside folder to the parent
    one, but there would already be a folder named "tools", so it would generate a
    conflict.
    
    This change first renames the inside folder to a random string, and only then
    it is moved outside and the old extraction folder is deleted.
    49d34d00
Name
Last commit
Last update
.github Loading commit data...
cache Loading commit data...
custom Loading commit data...
lib Loading commit data...
log Loading commit data...
plugins Loading commit data...
templates Loading commit data...
themes Loading commit data...
tools Loading commit data...
.editorconfig Loading commit data...
.gitignore Loading commit data...
.gitpod.Dockerfile Loading commit data...
.gitpod.yml Loading commit data...
.prettierrc Loading commit data...
CODE_OF_CONDUCT.md Loading commit data...
CONTRIBUTING.md Loading commit data...
LICENSE.txt Loading commit data...
README.md Loading commit data...
SECURITY.md Loading commit data...
oh-my-zsh.sh Loading commit data...