Skip to content

Commit b4ba8da

Browse files
authored
Merge pull request #1422 from aparcar/ln-short
util: use short `ln` options for Busybox compat
2 parents 67c7c58 + c56347e commit b4ba8da

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

labgrid/util/managedfile.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -74,9 +74,9 @@ def sync_to_resource(self, symlink=None):
7474
conn.run_check(f"test ! -e {symlink} -o -L {symlink}")
7575
except ExecutionError:
7676
raise ManagedFileError(f"Path {symlink} exists but is not a symlink.")
77-
conn.run_check(
78-
f"ln --symbolic --force --no-dereference {self.rpath}{os.path.basename(self.local_path)} {symlink}" # pylint: disable=line-too-long
79-
)
77+
# use short options to be compatible with busybox
78+
# --symbolic --force --no-dereference
79+
conn.run_check(f"ln -sfn {self.rpath}{os.path.basename(self.local_path)} {symlink}")
8080

8181

8282
def _on_nfs(self, conn):

0 commit comments

Comments
 (0)