File tree Expand file tree Collapse file tree 1 file changed +6
-18
lines changed
Expand file tree Collapse file tree 1 file changed +6
-18
lines changed Original file line number Diff line number Diff line change @@ -17,26 +17,14 @@ MOUNTS["${ROOT}/custom_nodes"]="/data/config/comfy/custom_nodes"
1717MOUNTS[" ${ROOT} /user" ]=" /data/config/comfy/user"
1818
1919for to_path in " ${! MOUNTS[@]} " ; do
20-
21- from_path=" ${MOUNTS[$to_path]} "
22-
23- # Make sure the source exists
24- if [ ! -e " $from_path " ]; then
20+ from_path=" ${MOUNTS[${to_path}]} "
21+ rm -rf " ${to_path} "
22+ if [ ! -f " $from_path " ]; then
2523 mkdir -vp " $from_path "
2624 fi
27-
28- # If destination already exists and is not a symlink
29- if [ -e " $to_path " ] && [ ! -L " $to_path " ]; then
30- echo " Moving contents from $to_path -> $from_path "
31- mv -v " $to_path " /* " $from_path " / 2> /dev/null || true
32- rm -rf " $to_path "
33- fi
34-
35- mkdir -vp " $( dirname " $to_path " ) "
36- ln -sT " $from_path " " $to_path "
37-
38- echo " Mounted $( basename " $from_path " ) "
39-
25+ mkdir -vp " $( dirname " ${to_path} " ) "
26+ ln -sT " ${from_path} " " ${to_path} "
27+ echo Mounted $( basename " ${from_path} " )
4028done
4129
4230if [ -f " /data/config/comfy/startup.sh" ]; then
You can’t perform that action at this time.
0 commit comments