859 force = True |
859 force = True |
860 accepted = True |
860 accepted = True |
861 else: |
861 else: |
862 from .SvnCopyDialog import SvnCopyDialog |
862 from .SvnCopyDialog import SvnCopyDialog |
863 dlg = SvnCopyDialog(name, None, True, force) |
863 dlg = SvnCopyDialog(name, None, True, force) |
864 accepted = (dlg.exec() == QDialog.Accepted) |
864 accepted = (dlg.exec() == QDialog.DialogCode.Accepted) |
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 |
980 else: |
980 else: |
981 url = self.svnNormalizeURL(reposURL) |
981 url = self.svnNormalizeURL(reposURL) |
982 from .SvnTagDialog import SvnTagDialog |
982 from .SvnTagDialog import SvnTagDialog |
983 dlg = SvnTagDialog(self.allTagsBranchesList, url, |
983 dlg = SvnTagDialog(self.allTagsBranchesList, url, |
984 self.otherData["standardLayout"]) |
984 self.otherData["standardLayout"]) |
985 if dlg.exec() == QDialog.Accepted: |
985 if dlg.exec() == QDialog.DialogCode.Accepted: |
986 tag, tagOp = dlg.getParameters() |
986 tag, tagOp = dlg.getParameters() |
987 if tag in self.allTagsBranchesList: |
987 if tag in self.allTagsBranchesList: |
988 self.allTagsBranchesList.remove(tag) |
988 self.allTagsBranchesList.remove(tag) |
989 self.allTagsBranchesList.insert(0, tag) |
989 self.allTagsBranchesList.insert(0, tag) |
990 else: |
990 else: |
1062 self.parent(), |
1062 self.parent(), |
1063 self.tr("Revert changes"), |
1063 self.tr("Revert changes"), |
1064 self.tr("Do you really want to revert all changes to" |
1064 self.tr("Do you really want to revert all changes to" |
1065 " these files or directories?"), |
1065 " these files or directories?"), |
1066 names) |
1066 names) |
1067 yes = dlg.exec() == QDialog.Accepted |
1067 yes = dlg.exec() == QDialog.DialogCode.Accepted |
1068 else: |
1068 else: |
1069 yes = E5MessageBox.yesNo( |
1069 yes = E5MessageBox.yesNo( |
1070 None, |
1070 None, |
1071 self.tr("Revert changes"), |
1071 self.tr("Revert changes"), |
1072 self.tr("""Do you really want to revert all changes of""" |
1072 self.tr("""Do you really want to revert all changes of""" |
1103 else: |
1103 else: |
1104 url = self.svnNormalizeURL(reposURL) |
1104 url = self.svnNormalizeURL(reposURL) |
1105 from .SvnSwitchDialog import SvnSwitchDialog |
1105 from .SvnSwitchDialog import SvnSwitchDialog |
1106 dlg = SvnSwitchDialog(self.allTagsBranchesList, url, |
1106 dlg = SvnSwitchDialog(self.allTagsBranchesList, url, |
1107 self.otherData["standardLayout"]) |
1107 self.otherData["standardLayout"]) |
1108 if dlg.exec() == QDialog.Accepted: |
1108 if dlg.exec() == QDialog.DialogCode.Accepted: |
1109 tag, tagType = dlg.getParameters() |
1109 tag, tagType = dlg.getParameters() |
1110 if tag in self.allTagsBranchesList: |
1110 if tag in self.allTagsBranchesList: |
1111 self.allTagsBranchesList.remove(tag) |
1111 self.allTagsBranchesList.remove(tag) |
1112 self.allTagsBranchesList.insert(0, tag) |
1112 self.allTagsBranchesList.insert(0, tag) |
1113 else: |
1113 else: |
1170 del opts[opts.index('--force')] |
1170 del opts[opts.index('--force')] |
1171 |
1171 |
1172 from .SvnMergeDialog import SvnMergeDialog |
1172 from .SvnMergeDialog import SvnMergeDialog |
1173 dlg = SvnMergeDialog( |
1173 dlg = SvnMergeDialog( |
1174 self.mergeList[0], self.mergeList[1], self.mergeList[2], force) |
1174 self.mergeList[0], self.mergeList[1], self.mergeList[2], force) |
1175 if dlg.exec() == QDialog.Accepted: |
1175 if dlg.exec() == QDialog.DialogCode.Accepted: |
1176 urlrev1, urlrev2, target, force = dlg.getParameters() |
1176 urlrev1, urlrev2, target, force = dlg.getParameters() |
1177 else: |
1177 else: |
1178 return |
1178 return |
1179 |
1179 |
1180 # remember URL or revision |
1180 # remember URL or revision |
1496 |
1496 |
1497 @param name directory name of the working directory (string) |
1497 @param name directory name of the working directory (string) |
1498 """ |
1498 """ |
1499 from .SvnCommandDialog import SvnCommandDialog |
1499 from .SvnCommandDialog import SvnCommandDialog |
1500 dlg = SvnCommandDialog(self.commandHistory, self.wdHistory, name) |
1500 dlg = SvnCommandDialog(self.commandHistory, self.wdHistory, name) |
1501 if dlg.exec() == QDialog.Accepted: |
1501 if dlg.exec() == QDialog.DialogCode.Accepted: |
1502 command, wd = dlg.getData() |
1502 command, wd = dlg.getData() |
1503 commandList = Utilities.parseOptionString(command) |
1503 commandList = Utilities.parseOptionString(command) |
1504 |
1504 |
1505 # This moves any previous occurrence of these arguments to the head |
1505 # This moves any previous occurrence of these arguments to the head |
1506 # of the list. |
1506 # of the list. |
1705 """ |
1705 """ |
1706 from .SvnCopyDialog import SvnCopyDialog |
1706 from .SvnCopyDialog import SvnCopyDialog |
1707 rx_prot = re.compile('(file:|svn:|svn+ssh:|http:|https:).+') |
1707 rx_prot = re.compile('(file:|svn:|svn+ssh:|http:|https:).+') |
1708 dlg = SvnCopyDialog(name) |
1708 dlg = SvnCopyDialog(name) |
1709 res = False |
1709 res = False |
1710 if dlg.exec() == QDialog.Accepted: |
1710 if dlg.exec() == QDialog.DialogCode.Accepted: |
1711 target, force = dlg.getData() |
1711 target, force = dlg.getData() |
1712 |
1712 |
1713 args = [] |
1713 args = [] |
1714 args.append('copy') |
1714 args.append('copy') |
1715 self.addArguments(args, self.options['global']) |
1715 self.addArguments(args, self.options['global']) |
1759 @param name file/directory name (string or list of strings) |
1759 @param name file/directory name (string or list of strings) |
1760 @param recursive flag indicating a recursive list is requested |
1760 @param recursive flag indicating a recursive list is requested |
1761 """ |
1761 """ |
1762 from .SvnPropSetDialog import SvnPropSetDialog |
1762 from .SvnPropSetDialog import SvnPropSetDialog |
1763 dlg = SvnPropSetDialog() |
1763 dlg = SvnPropSetDialog() |
1764 if dlg.exec() == QDialog.Accepted: |
1764 if dlg.exec() == QDialog.DialogCode.Accepted: |
1765 propName, fileFlag, propValue = dlg.getData() |
1765 propName, fileFlag, propValue = dlg.getData() |
1766 if not propName: |
1766 if not propName: |
1767 E5MessageBox.critical( |
1767 E5MessageBox.critical( |
1768 self.__ui, |
1768 self.__ui, |
1769 self.tr("Subversion Set Property"), |
1769 self.tr("Subversion Set Property"), |
1906 project = e5App().getObject("Project") |
1906 project = e5App().getObject("Project") |
1907 if nam == project.ppath and not project.saveAllScripts(): |
1907 if nam == project.ppath and not project.saveAllScripts(): |
1908 return |
1908 return |
1909 from .SvnRevisionSelectionDialog import SvnRevisionSelectionDialog |
1909 from .SvnRevisionSelectionDialog import SvnRevisionSelectionDialog |
1910 dlg = SvnRevisionSelectionDialog() |
1910 dlg = SvnRevisionSelectionDialog() |
1911 if dlg.exec() == QDialog.Accepted: |
1911 if dlg.exec() == QDialog.DialogCode.Accepted: |
1912 revisions = dlg.getRevisions() |
1912 revisions = dlg.getRevisions() |
1913 from .SvnDiffDialog import SvnDiffDialog |
1913 from .SvnDiffDialog import SvnDiffDialog |
1914 self.diff = SvnDiffDialog(self) |
1914 self.diff = SvnDiffDialog(self) |
1915 self.diff.show() |
1915 self.diff.show() |
1916 self.diff.start(name, revisions) |
1916 self.diff.start(name, revisions) |
1946 dname = self.splitPath(names[0])[0] |
1946 dname = self.splitPath(names[0])[0] |
1947 |
1947 |
1948 from .SvnUrlSelectionDialog import SvnUrlSelectionDialog |
1948 from .SvnUrlSelectionDialog import SvnUrlSelectionDialog |
1949 dlg = SvnUrlSelectionDialog(self, self.tagsList, self.branchesList, |
1949 dlg = SvnUrlSelectionDialog(self, self.tagsList, self.branchesList, |
1950 dname) |
1950 dname) |
1951 if dlg.exec() == QDialog.Accepted: |
1951 if dlg.exec() == QDialog.DialogCode.Accepted: |
1952 urls, summary = dlg.getURLs() |
1952 urls, summary = dlg.getURLs() |
1953 from .SvnDiffDialog import SvnDiffDialog |
1953 from .SvnDiffDialog import SvnDiffDialog |
1954 self.diff = SvnDiffDialog(self) |
1954 self.diff = SvnDiffDialog(self) |
1955 self.diff.show() |
1955 self.diff.show() |
1956 QApplication.processEvents() |
1956 QApplication.processEvents() |
2013 raise ValueError("Wrong parameter type") |
2013 raise ValueError("Wrong parameter type") |
2014 |
2014 |
2015 if extended: |
2015 if extended: |
2016 from .SvnRevisionSelectionDialog import SvnRevisionSelectionDialog |
2016 from .SvnRevisionSelectionDialog import SvnRevisionSelectionDialog |
2017 dlg = SvnRevisionSelectionDialog() |
2017 dlg = SvnRevisionSelectionDialog() |
2018 if dlg.exec() == QDialog.Accepted: |
2018 if dlg.exec() == QDialog.DialogCode.Accepted: |
2019 rev1, rev2 = dlg.getRevisions() |
2019 rev1, rev2 = dlg.getRevisions() |
2020 if rev1 == "WORKING": |
2020 if rev1 == "WORKING": |
2021 rev1 = "" |
2021 rev1 = "" |
2022 if rev2 == "WORKING": |
2022 if rev2 == "WORKING": |
2023 rev2 = "" |
2023 rev2 = "" |
2145 @param projectPath path name of the project (string) |
2145 @param projectPath path name of the project (string) |
2146 """ |
2146 """ |
2147 from .SvnRelocateDialog import SvnRelocateDialog |
2147 from .SvnRelocateDialog import SvnRelocateDialog |
2148 currUrl = self.svnGetReposName(projectPath) |
2148 currUrl = self.svnGetReposName(projectPath) |
2149 dlg = SvnRelocateDialog(currUrl) |
2149 dlg = SvnRelocateDialog(currUrl) |
2150 if dlg.exec() == QDialog.Accepted: |
2150 if dlg.exec() == QDialog.DialogCode.Accepted: |
2151 newUrl, inside = dlg.getData() |
2151 newUrl, inside = dlg.getData() |
2152 args = [] |
2152 args = [] |
2153 args.append('switch') |
2153 args.append('switch') |
2154 if not inside: |
2154 if not inside: |
2155 args.append('--relocate') |
2155 args.append('--relocate') |
2176 if url is None: |
2176 if url is None: |
2177 url, ok = QInputDialog.getText( |
2177 url, ok = QInputDialog.getText( |
2178 None, |
2178 None, |
2179 self.tr("Repository Browser"), |
2179 self.tr("Repository Browser"), |
2180 self.tr("Enter the repository URL."), |
2180 self.tr("Enter the repository URL."), |
2181 QLineEdit.Normal) |
2181 QLineEdit.EchoMode.Normal) |
2182 if not ok or not url: |
2182 if not ok or not url: |
2183 return |
2183 return |
2184 |
2184 |
2185 if self.repoBrowser is None: |
2185 if self.repoBrowser is None: |
2186 from .SvnRepoBrowserDialog import SvnRepoBrowserDialog |
2186 from .SvnRepoBrowserDialog import SvnRepoBrowserDialog |