eric6/Plugins/VcsPlugins/vcsSubversion/subversion.py

changeset 8234
fcb6b4b96274
parent 8205
4a0f1f896341
child 8259
2bbec88047dd
equal deleted inserted replaced
8233:bad78a592cc2 8234:fcb6b4b96274
865 if accepted: 865 if accepted:
866 target, force = dlg.getData() 866 target, force = dlg.getData()
867 if not target: 867 if not target:
868 return False 868 return False
869 869
870 if rx_prot.fullmatch(target) is None: 870 isDir = (os.path.isdir(name) if rx_prot.fullmatch(target) is None
871 isDir = os.path.isdir(name) 871 else False)
872 else:
873 isDir = False
874 872
875 if accepted: 873 if accepted:
876 args = [] 874 args = []
877 args.append('move') 875 args.append('move')
878 self.addArguments(args, opts) 876 self.addArguments(args, opts)
917 being edited and has unsaved modification, they can be saved or the 915 being edited and has unsaved modification, they can be saved or the
918 operation may be aborted. 916 operation may be aborted.
919 917
920 @param name file/directory name to be diffed (string) 918 @param name file/directory name to be diffed (string)
921 """ 919 """
922 if isinstance(name, list): 920 names = name[:] if isinstance(name, list) else [name]
923 names = name[:]
924 else:
925 names = [name]
926 for nam in names: 921 for nam in names:
927 if os.path.isfile(nam): 922 if os.path.isfile(nam):
928 editor = e5App().getObject("ViewManager").getOpenEditor(nam) 923 editor = e5App().getObject("ViewManager").getOpenEditor(nam)
929 if editor and not editor.checkDirty(): 924 if editor and not editor.checkDirty():
930 return 925 return
1891 1886
1892 This method gives the chance to enter the revisions to be compared. 1887 This method gives the chance to enter the revisions to be compared.
1893 1888
1894 @param name file/directory name to be diffed (string) 1889 @param name file/directory name to be diffed (string)
1895 """ 1890 """
1896 if isinstance(name, list): 1891 names = name[:] if isinstance(name, list) else [name]
1897 names = name[:]
1898 else:
1899 names = [name]
1900 for nam in names: 1892 for nam in names:
1901 if os.path.isfile(nam): 1893 if os.path.isfile(nam):
1902 editor = e5App().getObject("ViewManager").getOpenEditor(nam) 1894 editor = e5App().getObject("ViewManager").getOpenEditor(nam)
1903 if editor and not editor.checkDirty(): 1895 if editor and not editor.checkDirty():
1904 return 1896 return
1927 1919
1928 This method gives the chance to enter the revisions to be compared. 1920 This method gives the chance to enter the revisions to be compared.
1929 1921
1930 @param name file/directory name to be diffed (string) 1922 @param name file/directory name to be diffed (string)
1931 """ 1923 """
1932 if isinstance(name, list): 1924 names = name[:] if isinstance(name, list) else [name]
1933 names = name[:]
1934 else:
1935 names = [name]
1936 for nam in names: 1925 for nam in names:
1937 if os.path.isfile(nam): 1926 if os.path.isfile(nam):
1938 editor = e5App().getObject("ViewManager").getOpenEditor(nam) 1927 editor = e5App().getObject("ViewManager").getOpenEditor(nam)
1939 if editor and not editor.checkDirty(): 1928 if editor and not editor.checkDirty():
1940 return 1929 return
2166 """ 2155 """
2167 Public method to open the repository browser. 2156 Public method to open the repository browser.
2168 2157
2169 @param projectPath path name of the project (string) 2158 @param projectPath path name of the project (string)
2170 """ 2159 """
2171 if projectPath: 2160 url = self.svnGetReposName(projectPath) if projectPath else None
2172 url = self.svnGetReposName(projectPath)
2173 else:
2174 url = None
2175 2161
2176 if url is None: 2162 if url is None:
2177 url, ok = QInputDialog.getText( 2163 url, ok = QInputDialog.getText(
2178 None, 2164 None,
2179 self.tr("Repository Browser"), 2165 self.tr("Repository Browser"),

eric ide

mercurial