aguslr / multibootusb

A collection of GRUB files and scripts that will allow you to create a pendrive capable of booting different ISO files
https://mbusb.aguslr.com
GNU General Public License v3.0
571 stars 154 forks source link

Fix non-fatal error when using the --clone parameter #239

Closed rhssk closed 5 years ago

rhssk commented 5 years ago

See commit message.

Previous code suspiciously looks like it was intended to only move hidden files starting with .git. If that was really the reason (I can't imagine why though) a different approach might be needed.

Cheers

aguslr commented 5 years ago

Hello, @rhssk! I'm not quite sure I understand what benefit this brings. Currenty only the hidden files that start with .git are copied because those are the only hidden files that exist when cloning the repository.

rhssk commented 5 years ago

When using the --clone parameter, only .git, .gitattributes, .gitignore and .gitlab-ci.yml hidden files get moved over. .editorconfig remains in the temporary directory and [ -d "$repo_dir" ] && rmdir "$repo_dir" fails with rmdir: failed to remove '/tmp/repo.XXXX': Directory not empty.

It would be cleaner if all repo files were copied and script doesn't exit with 1.

aguslr commented 5 years ago

Oh, you're right. Wow! I totally forgot about the .editorconfig file. :astonished: I guess this is also related to #243.

Thanks for the PR, @rhssk!