Skip to content

Commit

Permalink
minor fix in log message
Browse files Browse the repository at this point in the history
  • Loading branch information
takuma-yoneda committed Dec 28, 2023
1 parent 2eb2ea1 commit d3bb4fa
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lmn/cli/_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ def rsync(source_dir: Union[Path, str], target_dir: Union[Path, str], remote_con

source_dir = str(source_dir).rstrip('/') + ('' if transfer_rootdir else '/')
target_dir = str(target_dir).rstrip('/') + '/'
logger.info(f"Syncing code... ({remote_conf.base_uri}:{target_dir})")

# TODO: Move the ControlPath to global config
options += [f'-e "ssh -o \'ControlPath=~/.ssh/lmn-ssh-socket-{remote_conf.host}\'"']
Expand All @@ -40,8 +39,10 @@ def rsync(source_dir: Union[Path, str], target_dir: Union[Path, str], remote_con
options_str = ' '.join(options)
if to_local:
cmd = f"rsync {options_str} {remote_conf.base_uri}:{source_dir} {target_dir}"
logger.info(f"Syncing files ({remote_conf.base_uri}:{source_dir} to {target_dir})")
else:
cmd = f"rsync {options_str} {source_dir} {remote_conf.base_uri}:{target_dir}"
logger.info(f"Syncing files ({source_dir} to {remote_conf.base_uri}:{target_dir})")

if not dry_run:
run_cmd(cmd, shell=True)
Expand Down

0 comments on commit d3bb4fa

Please sign in to comment.