diff --git a/sshare b/sshare index 8236ff0..b3a3609 100755 --- a/sshare +++ b/sshare @@ -3,6 +3,7 @@ import getpass import importlib.util import os +import pyclip import time import subprocess import sys @@ -11,12 +12,15 @@ def main(): config = Config() id = time.time_ns() + file_name = f"{id}.png" + + pyclip.copy(f"https://{config.ssh_target}/sshare/{file_name}") subprocess.run([ "scp", f"-P {config.ssh_port}", f"/home/gnarwhal/Pictures/Screenshots/Screenshot from 2024-07-31 06-34-57.png", - f"{config.ssh_user}@{config.ssh_domain}:{config.ssh_dir}/{id}.png", + f"{config.ssh_user}@{config.ssh_target}:{config.ssh_dir}/{file_name}", ]) @@ -24,7 +28,7 @@ class Config: def __init__(self): self.ssh_port = 2222 self.ssh_user = getpass.getuser() - self.ssh_domain = "monodon.me" + self.ssh_target = "monodon.me" self.ssh_dir = "~/sshare/"