mirror of
https://github.com/RetroDECK/RetroDECK.git
synced 2025-02-16 19:35:39 +00:00
WRAPPER: fixed dir_prep in order, was creating bad symlinks
This commit is contained in:
parent
7c17706a13
commit
b15a24ecc4
13
retrodeck.sh
13
retrodeck.sh
|
@ -34,17 +34,8 @@ dir_prep() {
|
||||||
|
|
||||||
# creating the symlink
|
# creating the symlink
|
||||||
echo "linking $real in $symlink" #DEBUG
|
echo "linking $real in $symlink" #DEBUG
|
||||||
mkdir -pv "$symlink" # creating the full path...
|
mkdir -pv "$(dirname "$symlink")" # creating the full path except the last folder
|
||||||
previous_dir=$PWD
|
ln -sv "$real" "$symlink"
|
||||||
cd "$symlink"
|
|
||||||
cd ..
|
|
||||||
echo "We are in $PWD" #DEBUG
|
|
||||||
ls -ln #DEBUG
|
|
||||||
rmdir -v "$symlink"
|
|
||||||
ln -sv "$real" .
|
|
||||||
echo "We are in $PWD" #DEBUG
|
|
||||||
ls -ln #DEBUG
|
|
||||||
cd $previous_dir
|
|
||||||
|
|
||||||
# moving everything from the old folder to the new one, delete the old one
|
# moving everything from the old folder to the new one, delete the old one
|
||||||
if [ -d "$symlink.old" ];
|
if [ -d "$symlink.old" ];
|
||||||
|
|
Loading…
Reference in a new issue