Browse Source

完成了git的clone功能,还欠缺移除缓存、删除关联和stdin

Huan 5 years ago
parent
commit
36e9a6277e
2 changed files with 162 additions and 113 deletions
  1. 108 93
      GIT.py
  2. 54 20
      Git_Ctrl.py

+ 108 - 93
GIT.py

@@ -31,13 +31,12 @@ def Main():
     a_y = 0
     a_x = 0
 
-    global clone_url
-    tkinter.Label(top, text='克隆URL:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
-    Dic_Var = tkinter.StringVar()#当前的Dic
-    clone_url = tkinter.Entry(top, width=width_B * 2, textvariable=Dic_Var)
-    clone_url.grid(column=a_x+1, row=a_y, columnspan=2, sticky=tkinter.E + tkinter.W)
+    global clone_url,Git_Box,Git_Dir
+    global commit_m,head,master,no_ff
+    global TagName,TagMessage,TagCommit,Show_Key
+    global RemoteSSH,RemoteName,RemoteBranch,LocalBranch,push_bind,allow_history
+    global BranchName, StashName, CommitName, BranchNOrigin
 
-    a_y += 1
     tkinter.Button(top, bg=bbg, fg=fg, text='克隆仓库', command=clone_git, font=FONT, width=width_B,
                    height=height_B).grid(column=a_x, row=a_y, sticky=tkinter.E + tkinter.W)
     tkinter.Button(top, bg=bbg, fg=fg, text='打开仓库', command=init_git, font=FONT, width=width_B,
@@ -45,7 +44,12 @@ def Main():
     tkinter.Button(top, bg=bbg, fg=fg, text='查看文件', command=get_Git_Dir, font=FONT, width=width_B,
                    height=height_B).grid(column=a_x+2, row=a_y, sticky=tkinter.E + tkinter.W)
 
-    global Git_Box,Git_Dir
+    a_y += 1
+    tkinter.Label(top, text='克隆URL:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
+    Dic_Var = tkinter.StringVar()#当前的Dic
+    clone_url = tkinter.Entry(top, width=width_B * 2, textvariable=Dic_Var)
+    clone_url.grid(column=a_x+1, row=a_y, columnspan=2, sticky=tkinter.E + tkinter.W)
+
     a_y += 1
     Git_Box = tkinter.Listbox(top, width=width_B * 3, height=height_B * 4)
     Git_Box.grid(column=a_x, row=a_y, columnspan=3, rowspan=4, sticky=tkinter.E + tkinter.W + tkinter.S + tkinter.N)
@@ -66,12 +70,6 @@ def Main():
     tkinter.Button(top, bg=bbg, fg=fg, text='提交到git', command=Commit_File, font=FONT, width=width_B,
                    height=height_B).grid(column=a_x+2, row=a_y, sticky=tkinter.E + tkinter.W)
 
-    global commit_m,head,master,no_ff
-    a_y += 1
-    tkinter.Label(top, text='提交描述:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
-    commit_m = tkinter.Entry(top, width=width_B * 2)
-    commit_m.grid(column=a_x + 1, row=a_y, columnspan=2, sticky=tkinter.E + tkinter.W)
-
     a_y += 1
     tkinter.Button(top, bg=bbg, fg=fg, text='查看执行日志', command=lambda :not_Args(Git.reflog), font=FONT, width=width_B,
                    height=height_B).grid(column=a_x, row=a_y, sticky=tkinter.E + tkinter.W)
@@ -88,16 +86,6 @@ def Main():
     tkinter.Button(top, bg=bbg, fg=fg, text='删除文件', command=rm_file, font=FONT, width=width_B,
                    height=height_B).grid(column=a_x+2, row=a_y, sticky=tkinter.E + tkinter.W)
 
-    a_y += 1
-    tkinter.Label(top, text='diff分支:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
-    master = tkinter.Entry(top, width=width_B * 2)
-    master.grid(column=a_x + 1, row=a_y, columnspan=2, sticky=tkinter.E + tkinter.W)
-
-    a_y += 1
-    tkinter.Label(top, text='回退版本号:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
-    head = tkinter.Entry(top, width=width_B * 2)
-    head.grid(column=a_x + 1, row=a_y, columnspan=2, sticky=tkinter.E + tkinter.W)
-
     a_y += 1
     tkinter.Button(top, bg=bbg, fg=fg, text='查看分支', command=lambda :not_Args(Git.check_Branch), font=FONT, width=width_B,
                    height=height_B).grid(column=a_x, row=a_y, sticky=tkinter.E + tkinter.W)
@@ -124,17 +112,6 @@ def Main():
                         variable=no_ff).grid(column=a_x + 1, row=a_y, sticky=tkinter.W)
     no_ff.set(0)
 
-    global BranchName,StashName,CommitName,BranchNOrigin
-    a_y += 1
-    tkinter.Label(top, text='分支名字:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
-    BranchName = tkinter.Entry(top, width=width_B * 2)
-    BranchName.grid(column=a_x + 1, row=a_y, columnspan=2, sticky=tkinter.E + tkinter.W)
-
-    a_y += 1
-    tkinter.Label(top, text='关联远程分支:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
-    BranchNOrigin = tkinter.Entry(top, width=width_B * 2)
-    BranchNOrigin.grid(column=a_x + 1, row=a_y, columnspan=2, sticky=tkinter.E + tkinter.W)
-
     a_y += 1
     tkinter.Button(top, bg=bbg, fg=fg, text='保存工作区', command=lambda :not_Args(Git.Save_stash), font=FONT, width=width_B,
                    height=height_B).grid(column=a_x, row=a_y, sticky=tkinter.E + tkinter.W)
@@ -143,37 +120,38 @@ def Main():
     tkinter.Button(top, bg=bbg, fg=fg, text='删除工作区', command=lambda :Open_Stash(0), font=FONT, width=width_B,
                    height=height_B).grid(column=a_x+2, row=a_y, sticky=tkinter.E + tkinter.W)
 
-    a_y += 1
-    tkinter.Label(top, text='工作区序号:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
-    StashName = tkinter.Entry(top, width=width_B)
-    StashName.grid(column=a_x + 1, row=a_y, sticky=tkinter.E + tkinter.W)
-    tkinter.Button(top, bg=bbg, fg=fg, text='工作区列表', command=lambda :not_Args(Git.Stash_List), font=FONT, width=width_B,
-                   height=height_B).grid(column=a_x+2, row=a_y, sticky=tkinter.E + tkinter.W)
-
-    a_y += 1
-    tkinter.Label(top, text='commit:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
-    CommitName = tkinter.Entry(top, width=width_B)
-    CommitName.grid(column=a_x + 1, row=a_y, sticky=tkinter.E + tkinter.W)
-    tkinter.Button(top, bg=bbg, fg=fg, text='复制commit', command=cherry_pick, font=FONT, width=width_B,
-                   height=height_B).grid(column=a_x+2, row=a_y, sticky=tkinter.E + tkinter.W)
-
     a_x += 3
     tkinter.Label(top, text='', bg=bg, fg=fg, font=FONT, width=1).grid(column=a_x, row=a_y)  # 设置说明
     a_x += 1
     a_y = 0
 
-    tkinter.Label(top, text='【远程仓库】', bg=bg, fg=fg, font=FONT, width=width_B * 3, height=height_B).grid(
+    tkinter.Label(top, text='【参数操作】', bg=bg, fg=fg, font=FONT, width=width_B * 3, height=height_B).grid(
         column=a_x,columnspan=3,row=a_y,sticky=tkinter.E + tkinter.W + tkinter.W + tkinter.S + tkinter.N)  # 设置说明
 
     a_y += 1
-    tkinter.Button(top, bg=bbg, fg=fg, text='连接远程仓库', command=Add_remote, font=FONT, width=width_B,
-                   height=height_B).grid(column=a_x, row=a_y, sticky=tkinter.E + tkinter.W)
-    tkinter.Button(top, bg=bbg, fg=fg, text='推送到远程仓库', command=lambda :Pull_Push_remote(1), font=FONT, width=width_B,
-                   height=height_B).grid(column=a_x+1, row=a_y, sticky=tkinter.E + tkinter.W)
-    tkinter.Button(top, bg=bbg, fg=fg, text='从远程仓库抓取', command=lambda :Pull_Push_remote(0), font=FONT, width=width_B,
-                   height=height_B).grid(column=a_x+2, row=a_y, sticky=tkinter.E + tkinter.W)
+    tkinter.Label(top, text='提交描述:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
+    commit_m = tkinter.Entry(top, width=width_B * 2)
+    commit_m.grid(column=a_x + 1, row=a_y, columnspan=2, sticky=tkinter.E + tkinter.W)
 
-    global RemoteSSH,RemoteName,RemoteBranch,LocalBranch,push_bind,allow_history
+    a_y += 1
+    tkinter.Label(top, text='diff分支:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
+    master = tkinter.Entry(top, width=width_B * 2)
+    master.grid(column=a_x + 1, row=a_y, columnspan=2, sticky=tkinter.E + tkinter.W)
+
+    a_y += 1
+    tkinter.Label(top, text='回退版本号:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
+    head = tkinter.Entry(top, width=width_B * 2)
+    head.grid(column=a_x + 1, row=a_y, columnspan=2, sticky=tkinter.E + tkinter.W)
+
+    a_y += 1
+    tkinter.Label(top, text='本地分支:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
+    BranchName = tkinter.Entry(top, width=width_B * 2)
+    BranchName.grid(column=a_x + 1, row=a_y, columnspan=2, sticky=tkinter.E + tkinter.W)
+
+    a_y += 1
+    tkinter.Label(top, text='远程分支:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
+    BranchNOrigin = tkinter.Entry(top, width=width_B * 2)
+    BranchNOrigin.grid(column=a_x + 1, row=a_y, columnspan=2, sticky=tkinter.E + tkinter.W)
 
     a_y += 1
     tkinter.Label(top, text='远程仓库链接:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
@@ -183,19 +161,35 @@ def Main():
     a_y += 1
     tkinter.Label(top, text='远程仓库名:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
     RemoteName = tkinter.Entry(top, width=width_B)
-    RemoteName.grid(column=a_x + 1, row=a_y, sticky=tkinter.E + tkinter.W)
-    tkinter.Button(top, bg=bbg, fg=fg, text='删除关联', command=cherry_pick, font=FONT, width=width_B,
-                   height=height_B).grid(column=a_x+2, row=a_y, sticky=tkinter.E + tkinter.W)
+    RemoteName.grid(column=a_x + 1, row=a_y, columnspan=2,sticky=tkinter.E + tkinter.W)
 
     a_y += 1
-    tkinter.Label(top, text='远程分支:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
-    RemoteBranch = tkinter.Entry(top, width=width_B)
-    RemoteBranch.grid(column=a_x + 1,columnspan=2, row=a_y, sticky=tkinter.E + tkinter.W)
+    tkinter.Label(top, text='commit:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
+    CommitName = tkinter.Entry(top, width=width_B)
+    CommitName.grid(column=a_x + 1, row=a_y, columnspan=2, sticky=tkinter.E + tkinter.W)
 
     a_y += 1
-    tkinter.Label(top, text='本地分支:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
-    LocalBranch = tkinter.Entry(top, width=width_B)
-    LocalBranch.grid(column=a_x + 1,columnspan=2, row=a_y, sticky=tkinter.E + tkinter.W)
+    tkinter.Label(top, text='标签名字:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
+    TagName = tkinter.Entry(top, width=width_B)
+    TagName.grid(column=a_x + 1,columnspan=2, row=a_y, sticky=tkinter.E + tkinter.W)
+
+    a_y += 1
+    tkinter.Label(top, text='查询关键字:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
+    Show_Key = tkinter.Entry(top, width=width_B)
+    Show_Key.grid(column=a_x + 1,columnspan=2, row=a_y, sticky=tkinter.E + tkinter.W)
+
+    a_y += 1
+    tkinter.Label(top, text='工作区序号:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
+    StashName = tkinter.Entry(top, width=width_B)
+    StashName.grid(column=a_x + 1, row=a_y,columnspan=2, sticky=tkinter.E + tkinter.W)
+
+    a_y += 1
+    tkinter.Button(top, bg=bbg, fg=fg, text='连接远程仓库', command=Add_remote, font=FONT, width=width_B,
+                   height=height_B).grid(column=a_x, row=a_y, sticky=tkinter.E + tkinter.W)
+    tkinter.Button(top, bg=bbg, fg=fg, text='推送到远程仓库', command=lambda :Pull_Push_remote(1), font=FONT, width=width_B,
+                   height=height_B).grid(column=a_x+1, row=a_y, sticky=tkinter.E + tkinter.W)
+    tkinter.Button(top, bg=bbg, fg=fg, text='从远程仓库抓取', command=lambda :Pull_Push_remote(0), font=FONT, width=width_B,
+                   height=height_B).grid(column=a_x+2, row=a_y, sticky=tkinter.E + tkinter.W)
 
     push_bind = tkinter.Variable()
     allow_history = tkinter.Variable()
@@ -209,27 +203,6 @@ def Main():
     allow_history.set(0)
     push_bind.set(0)
 
-    global TagName,TagMessage,TagCommit,Show_Key
-    a_y += 1
-    tkinter.Label(top, text='标签名字:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
-    TagName = tkinter.Entry(top, width=width_B)
-    TagName.grid(column=a_x + 1,columnspan=2, row=a_y, sticky=tkinter.E + tkinter.W)
-
-    a_y += 1
-    tkinter.Label(top, text='标签描述:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
-    TagMessage = tkinter.Entry(top, width=width_B)
-    TagMessage.grid(column=a_x + 1,columnspan=2, row=a_y, sticky=tkinter.E + tkinter.W)
-
-    a_y += 1
-    tkinter.Label(top, text='commit记录:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
-    TagCommit = tkinter.Entry(top, width=width_B)
-    TagCommit.grid(column=a_x + 1,columnspan=2, row=a_y, sticky=tkinter.E + tkinter.W)
-
-    a_y += 1
-    tkinter.Label(top, text='查询关键字:', bg=bg, fg=fg, font=FONT, width=width_B, height=height_B).grid(column=a_x,row=a_y)
-    Show_Key = tkinter.Entry(top, width=width_B)
-    Show_Key.grid(column=a_x + 1,columnspan=2, row=a_y, sticky=tkinter.E + tkinter.W)
-
     a_y += 1
     tkinter.Button(top, bg=bbg, fg=fg, text='应用标签', command=add_tag, font=FONT, width=width_B,
                    height=height_B).grid(column=a_x, row=a_y, sticky=tkinter.E + tkinter.W)
@@ -254,8 +227,57 @@ def Main():
     tkinter.Button(top, bg=bbg, fg=fg, text='刷新远程分支', command=Fetch_remote, font=FONT, width=width_B,
                    height=height_B).grid(column=a_x+2, row=a_y, sticky=tkinter.E + tkinter.W)
 
+    a_y += 1
+    tkinter.Button(top, bg=bbg, fg=fg, text='commit补丁', command=cherry_pick, font=FONT, width=width_B,
+                   height=height_B).grid(column=a_x, row=a_y, sticky=tkinter.E + tkinter.W)
+    tkinter.Button(top, bg=bbg, fg=fg, text='删除远程仓库', command=cherry_pick, font=FONT, width=width_B,
+                   height=height_B).grid(column=a_x+1, row=a_y, sticky=tkinter.E + tkinter.W)
+    tkinter.Button(top, bg=bbg, fg=fg, text='工作区列表', command=lambda :not_Args(Git.Stash_List), font=FONT, width=width_B,
+                   height=height_B).grid(column=a_x+2, row=a_y, sticky=tkinter.E + tkinter.W)
+
+    global Customize_Input, th_do, wait_do
+    a_y += 1
+    th_do = tkinter.Variable()
+    wait_do = tkinter.Variable()
+    tkinter.Checkbutton(top, bg=bg, fg=fg, activebackground=bg, activeforeground=fg, selectcolor=bg, text='多进程刷新',
+                        variable=th_do).grid(column=0, row=a_y, sticky=tkinter.W)
+    tkinter.Checkbutton(top, bg=bg, fg=fg, activebackground=bg, activeforeground=fg, selectcolor=bg, text='异步显示',
+                        variable=wait_do).grid(column=1, row=a_y, sticky=tkinter.W)
+    Customize_Input = tkinter.Entry(top, width=width_B * 3)
+    Customize_Input.grid(column=2, row=a_y, columnspan=4, sticky=tkinter.E + tkinter.W + tkinter.N + tkinter.S)
+
+    tkinter.Button(top, bg=bbg, fg=fg, text='执行操作', command=Customize, font=FONT, width=width_B,
+                   height=height_B).grid(column=a_x+2, row=a_y, sticky=tkinter.E + tkinter.W)
+    th_do.set(0)
+    wait_do.set(1)
+    TagMessage = commit_m
+    TagCommit = CommitName
+    RemoteBranch = BranchNOrigin
+    LocalBranch = BranchName
+
     top.mainloop()
 
+def clone_git():#克隆仓库
+    global clone_url
+    new_Dic = askdirectory(title = '选择仓库地址')
+    if new_Dic == '':return False
+    name = Git.Clone_init(new_Dic)
+    Clone(name, clone_url.get())
+    Updata_GitBox()
+
+def Clone(name,url):
+    do_Sys(Git.Clone, (name, url),
+           break_time=0,text_n=f'{url}:正在执行克隆操作',th=True,wait=True)
+    Git.After_Clone(name)
+    update_Git_Dir()
+
+def Customize():
+    global Git, Customize_Input, th_do, wait_do
+    command = Customize_Input.get()
+    do_Sys(Git.Customize, (get_Name(), command),
+           break_time=0,text_n=f'{command}:操作进行中',th=bool(th_do.get()),wait=bool(wait_do.get()))
+    update_Git_Dir()
+
 def Fetch_remote():
     global RemoteBranch, LocalBranch, Git, RemoteName
     Branch = RemoteBranch.get()
@@ -603,13 +625,6 @@ def Git_dir(name):
         pass
     Last_Name = name
 
-def clone_git():#克隆仓库
-    global clone_url
-    new_Dic = askdirectory(title = '选择仓库地址')
-    if new_Dic == '':return False
-    Git.Clone_init(new_Dic, clone_url.get())
-    Updata_GitBox()
-
 def init_git():#创建仓库
     global Git
     new_Dic = askdirectory(title = '选择仓库地址')

+ 54 - 20
Git_Ctrl.py

@@ -8,13 +8,20 @@ sys_seeting = dict(shell=True,stdin=subprocess.PIPE,stdout=subprocess.PIPE,stder
 git_path = 'git'
 
 class git_Repo:#git的基类
-    def __init__(self,Dic,name,*args,**kwargs):
-        self.Repo_Dic = Dic  # 仓库地址
+    def __init__(self,Dic,*args,**kwargs):
         self.url = None
-        if not exists(Dic + r'/.git'):  # 是否为git 仓库
+        try:
+            if exists(Dic + r'/.git'):  # 是否为git 仓库
+                pass
+            elif Dic[-4:] =='.git':
+                Dic = Dic[:-5]  # -5,得把/去掉
+            else:raise Exception
+        except:
             subprocess.Popen(f'{git_path} init',cwd=self.Repo_Dic,**sys_seeting).wait()
+        self.Repo_Dic = Dic  # 仓库地址(末尾不带/)
         self.repo = Repo(Dic)
-        self.name = name
+        self.name = split(Dic)[-1]
+        self.have_clone = True
 
     def Flie_List(self,file_list,is_file=True,pat=' '):
         if file_list == '.':
@@ -220,13 +227,27 @@ class git_Repo:#git的基类
 
         return subprocess.Popen(f'''{git_path} fetch {remote_name} {branch}''', cwd=self.Repo_Dic, **sys_seeting)
 
+    def Customize(self,command:str):
+        return subprocess.Popen(command,cwd=self.Repo_Dic, **sys_seeting)
+
+    def Clone(self,url):
+        return subprocess.Popen(f'echo 无法克隆', cwd=self.Repo_Dic, **sys_seeting)
+
 class Clone_git(git_Repo):#Clone一个git
-    def __init__(self,Dic,url,name,*args,**kwargs):
-        super(Clone_git, self).__init__(Dic,name, *args, **kwargs)
-        self.url = url
-        Repo.clone_from(url=url,to_path=Dic)
-        self.git = self.repo.git
-        self.index = self.repo.index
+    def __init__(self, Dic, *args, **kwargs):
+        self.Repo_Dic = Dic  # 仓库地址
+        self.url = None
+        self.name = split(Dic)[-1]
+        self.have_clone = False
+
+    def Clone(self,url):
+        if self.have_clone:super(Clone_git, self).Clone(url)
+        self.have_clone = True
+        return subprocess.Popen(f'{git_path} clone {url} {self.Repo_Dic}', cwd=split(self.Repo_Dic)[0], **sys_seeting)
+
+    def after_Clone(self):
+        print('F')
+        self.repo = Repo(self.Repo_Dic)
 
 class git_Ctrol:
     def __init__(self):
@@ -234,16 +255,16 @@ class git_Ctrol:
         self.gitType_Dic = {}#名字-类型
 
     def Add_init(self,Dic,**kwargs):
-        name = split(Dic)[-1]
-        git = git_Repo(Dic,name)
-        self.git_Dic[name] = git
-        self.gitType_Dic[name] = 'init'
+        git = git_Repo(Dic)
+        self.git_Dic[git.name] = git
+        self.gitType_Dic[git.name] = 'init'
+        return git.name
 
-    def Clone_init(self,Dic,url,**kwargs):
-        name = split(Dic)[-1]
-        git = Clone_git(Dic,url,name)
-        self.git_Dic[name] = git
-        self.gitType_Dic[name] = 'clone'
+    def Clone_init(self,Dic,**kwargs):
+        git = Clone_git(Dic)
+        self.git_Dic[git.name] = git
+        self.gitType_Dic[git.name] = 'clone'
+        return git.name
 
     def get_git(self,name):
         return self.git_Dic[name]
@@ -352,4 +373,17 @@ class git_Ctrol:
         return self.get_git(name).del_tag(tag)
 
     def Fetch(self,name,local_name,remote_name,remote_branch):
-        return self.get_git(name).fetch(remote_name,remote_branch,local_name)
+        return self.get_git(name).fetch(remote_name,remote_branch,local_name)
+
+    def Customize(self,name,command:str):
+        return self.get_git(name).Customize(command)
+
+    def Clone(self,name,url):
+        return self.get_git(name).Clone(url)
+
+    def After_Clone(self,name):
+        try:
+            return self.get_git(name).after_Clone()
+        except:
+            # return None
+            raise