Skip to content

Commit 989b81e

Browse files
committed
use copy for gh components
1 parent 63cbfe6 commit 989b81e

File tree

1 file changed

+11
-2
lines changed

1 file changed

+11
-2
lines changed

src/compas_ghpython/components/__init__.py

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,9 @@
2626
import glob
2727
import os
2828

29-
from compas._os import create_symlinks
29+
# from compas._os import create_symlinks
3030
from compas._os import remove_symlinks
31+
from compas._os import copy as _copy
3132
from compas_ghpython import get_grasshopper_userobjects_path
3233
from compas_rhino import _check_rhino_version
3334
import compas_rhino
@@ -75,7 +76,15 @@ def install_userobjects(source):
7576
remove_symlinks(symlinks_to_remove)
7677

7778
# And the create new ones
78-
created = create_symlinks(symlinks_to_add)
79+
# created = create_symlinks(symlinks_to_add)
80+
created = []
81+
for src, dst in symlinks_to_add:
82+
try:
83+
_copy(src, dst)
84+
except Exception:
85+
created.append(False)
86+
else:
87+
created.append(True)
7988

8089
return list(zip(symlinks_to_add, created))
8190

0 commit comments

Comments
 (0)