# @Author: Lee
# @Filename: SynchronizeFile
# @Date: 2020-07-29-11-37
# @E-MAIL: 654994961@qq.com
# __author__ == 'ljh'
from tkinter import *
# 制作GUI界面
import paramiko
# 用来远程
import time
from tqdm import tqdm
# 用来显示进程
import os
class Application(Frame):
def __init__(self, master):
super(Application, self).__init__(master)
# 继承超类/父类的初始化
Label(self, text='Remote Data Dir').grid(row=0, column=0, sticky=W, padx=0, pady=0)
default_remote_dir = StringVar()
# 字符变量
default_remote_dir.set(r'/备站备份/')
self.remote_dir_ent = Entry(self, textvariable=default_remote_dir, width=52)
# width值是自己摸索的 grid()来布局需要自己重复的实验,以求找到最合适的大小
self.remote_dir_ent.grid(row=0, column=1, columnspan=3, sticky=W, padx=0, pady=0)
Label(self, text='Local Data Dir').grid(row=1, column=0, sticky=W, padx=0, pady=0)
default_local_dir = StringVar()
default_local_dir.set(r'D:\ljh\untitled\sdv')
self.local_dir_ent = Entry(self, textvariable=default_local_dir, width=52)
self.local_dir_ent.grid(row=1, column=1, columnspan=3, sticky=W, padx=0, pady=0)
Label(self, text='
Python之paramiko、tkinter实现远程数据备份的桌面程序
最新推荐文章于 2023-06-26 11:44:06 发布