From 81c9b35c75d6f0395601736230accdb69369b82f Mon Sep 17 00:00:00 2001 From: Cuan Date: Wed, 16 Feb 2022 09:27:22 -0500 Subject: [PATCH] Rename deletion check function --- bin/sshyp | 2 +- bin/sshyp-remote.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/sshyp b/bin/sshyp index 2c59075..42e8525 100755 --- a/bin/sshyp +++ b/bin/sshyp @@ -211,7 +211,7 @@ def sync(): # calls sshync to sync changes to the user's server print('\nSyncing entries with the server device...\n') # check for deletions system(f"ssh -i '{path.expanduser('~/.ssh/sshyp')}' -p {port} {username_ssh}@{ip} \"python -c 'import sshyp-remote" - f"; shear.check(\"'\"{client_device_name}\"'\")'\"") + f"; shear.deletion_check(\"'\"{client_device_name}\"'\")'\"") system(f"sftp -p -q -i '{path.expanduser('~/.ssh/sshyp')}' -P {port} {username_ssh}@{ip}:" f"'/home/{username_ssh}/.config/sshyp/deletion_database' {path.expanduser('~/.config/sshyp/')}") try: diff --git a/bin/sshyp-remote.py b/bin/sshyp-remote.py index da3df65..789ea14 100755 --- a/bin/sshyp-remote.py +++ b/bin/sshyp-remote.py @@ -24,7 +24,7 @@ def delete(_file_path): open(f"{expanduser('~/.config/sshyp/deleted/')}{_file_path.replace('/', '@')}^&*{_device_name}", 'w') -def check(_client_device_name): +def deletion_check(_client_device_name): open(expanduser('~/.config/sshyp/deletion_database'), 'w').write('') for _file in listdir(expanduser('~/.config/sshyp/deleted')): _file_path = _file.replace('@', '/').split('^&*')[0]