forked from qt-creator/qt-creator
Adapt to upstream changes
* FilePathification * SynchronousProcess -> QtcProcess Change-Id: I973ff68585788c8742652f69a7c057e28aafbaf4 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
This commit is contained in:
@@ -261,8 +261,8 @@ unsigned int FossilClient::synchronousBinaryVersion() const
|
|||||||
|
|
||||||
QStringList args("version");
|
QStringList args("version");
|
||||||
|
|
||||||
SynchronousProcess proc;
|
QtcProcess proc;
|
||||||
vcsFullySynchronousExec(proc, QString(), args);
|
vcsFullySynchronousExec(proc, FilePath(), args);
|
||||||
if (proc.result() != QtcProcess::Finished)
|
if (proc.result() != QtcProcess::Finished)
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
@@ -294,13 +294,13 @@ QList<BranchInfo> FossilClient::branchListFromOutput(const QString &output, cons
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
BranchInfo FossilClient::synchronousCurrentBranch(const QString &workingDirectory)
|
BranchInfo FossilClient::synchronousCurrentBranch(const FilePath &workingDirectory)
|
||||||
{
|
{
|
||||||
if (workingDirectory.isEmpty())
|
if (workingDirectory.isEmpty())
|
||||||
return BranchInfo();
|
return BranchInfo();
|
||||||
|
|
||||||
// First try to get the current branch from the list of open branches
|
// First try to get the current branch from the list of open branches
|
||||||
SynchronousProcess proc;
|
QtcProcess proc;
|
||||||
vcsFullySynchronousExec(proc, workingDirectory, {"branch", "list"});
|
vcsFullySynchronousExec(proc, workingDirectory, {"branch", "list"});
|
||||||
if (proc.result() != QtcProcess::Finished)
|
if (proc.result() != QtcProcess::Finished)
|
||||||
return BranchInfo();
|
return BranchInfo();
|
||||||
@@ -312,7 +312,7 @@ BranchInfo FossilClient::synchronousCurrentBranch(const QString &workingDirector
|
|||||||
|
|
||||||
if (!currentBranch.isCurrent()) {
|
if (!currentBranch.isCurrent()) {
|
||||||
// If not available from open branches, request it from the list of closed branches.
|
// If not available from open branches, request it from the list of closed branches.
|
||||||
SynchronousProcess proc;
|
QtcProcess proc;
|
||||||
vcsFullySynchronousExec(proc, workingDirectory, {"branch", "list", "--closed"});
|
vcsFullySynchronousExec(proc, workingDirectory, {"branch", "list", "--closed"});
|
||||||
if (proc.result() != QtcProcess::Finished)
|
if (proc.result() != QtcProcess::Finished)
|
||||||
return BranchInfo();
|
return BranchInfo();
|
||||||
@@ -326,7 +326,7 @@ BranchInfo FossilClient::synchronousCurrentBranch(const QString &workingDirector
|
|||||||
return currentBranch;
|
return currentBranch;
|
||||||
}
|
}
|
||||||
|
|
||||||
QList<BranchInfo> FossilClient::synchronousBranchQuery(const QString &workingDirectory)
|
QList<BranchInfo> FossilClient::synchronousBranchQuery(const FilePath &workingDirectory)
|
||||||
{
|
{
|
||||||
// Return a list of all branches, including the closed ones.
|
// Return a list of all branches, including the closed ones.
|
||||||
// Sort the list by branch name.
|
// Sort the list by branch name.
|
||||||
@@ -335,7 +335,7 @@ QList<BranchInfo> FossilClient::synchronousBranchQuery(const QString &workingDir
|
|||||||
return QList<BranchInfo>();
|
return QList<BranchInfo>();
|
||||||
|
|
||||||
// First get list of open branches
|
// First get list of open branches
|
||||||
SynchronousProcess proc;
|
QtcProcess proc;
|
||||||
vcsFullySynchronousExec(proc, workingDirectory, {"branch", "list"});
|
vcsFullySynchronousExec(proc, workingDirectory, {"branch", "list"});
|
||||||
if (proc.result() != QtcProcess::Finished)
|
if (proc.result() != QtcProcess::Finished)
|
||||||
return QList<BranchInfo>();
|
return QList<BranchInfo>();
|
||||||
@@ -371,7 +371,8 @@ QStringList FossilClient::parseRevisionCommentLine(const QString &commentLine)
|
|||||||
return QStringList({match.captured(1), match.captured(2)});
|
return QStringList({match.captured(1), match.captured(2)});
|
||||||
}
|
}
|
||||||
|
|
||||||
RevisionInfo FossilClient::synchronousRevisionQuery(const QString &workingDirectory, const QString &id,
|
RevisionInfo FossilClient::synchronousRevisionQuery(const FilePath &workingDirectory,
|
||||||
|
const QString &id,
|
||||||
bool getCommentMsg) const
|
bool getCommentMsg) const
|
||||||
{
|
{
|
||||||
// Query details of the given revision/check-out id,
|
// Query details of the given revision/check-out id,
|
||||||
@@ -383,7 +384,7 @@ RevisionInfo FossilClient::synchronousRevisionQuery(const QString &workingDirect
|
|||||||
if (!id.isEmpty())
|
if (!id.isEmpty())
|
||||||
args << id;
|
args << id;
|
||||||
|
|
||||||
SynchronousProcess proc;
|
QtcProcess proc;
|
||||||
vcsFullySynchronousExec(proc, workingDirectory, args, ShellCommand::SuppressCommandLogging);
|
vcsFullySynchronousExec(proc, workingDirectory, args, ShellCommand::SuppressCommandLogging);
|
||||||
if (proc.result() != QtcProcess::Finished)
|
if (proc.result() != QtcProcess::Finished)
|
||||||
return RevisionInfo();
|
return RevisionInfo();
|
||||||
@@ -433,7 +434,7 @@ RevisionInfo FossilClient::synchronousRevisionQuery(const QString &workingDirect
|
|||||||
return RevisionInfo(revisionId, parentId, mergeParentIds, commentMsg, committer);
|
return RevisionInfo(revisionId, parentId, mergeParentIds, commentMsg, committer);
|
||||||
}
|
}
|
||||||
|
|
||||||
QStringList FossilClient::synchronousTagQuery(const QString &workingDirectory, const QString &id)
|
QStringList FossilClient::synchronousTagQuery(const FilePath &workingDirectory, const QString &id)
|
||||||
{
|
{
|
||||||
// Return a list of tags for the given revision.
|
// Return a list of tags for the given revision.
|
||||||
// If no revision specified, all defined tags are listed.
|
// If no revision specified, all defined tags are listed.
|
||||||
@@ -447,7 +448,7 @@ QStringList FossilClient::synchronousTagQuery(const QString &workingDirectory, c
|
|||||||
if (!id.isEmpty())
|
if (!id.isEmpty())
|
||||||
args << id;
|
args << id;
|
||||||
|
|
||||||
SynchronousProcess proc;
|
QtcProcess proc;
|
||||||
vcsFullySynchronousExec(proc, workingDirectory, args);
|
vcsFullySynchronousExec(proc, workingDirectory, args);
|
||||||
if (proc.result() != QtcProcess::Finished)
|
if (proc.result() != QtcProcess::Finished)
|
||||||
return QStringList();
|
return QStringList();
|
||||||
@@ -457,7 +458,7 @@ QStringList FossilClient::synchronousTagQuery(const QString &workingDirectory, c
|
|||||||
return output.split('\n', Qt::SkipEmptyParts);
|
return output.split('\n', Qt::SkipEmptyParts);
|
||||||
}
|
}
|
||||||
|
|
||||||
RepositorySettings FossilClient::synchronousSettingsQuery(const QString &workingDirectory)
|
RepositorySettings FossilClient::synchronousSettingsQuery(const FilePath &workingDirectory)
|
||||||
{
|
{
|
||||||
if (workingDirectory.isEmpty())
|
if (workingDirectory.isEmpty())
|
||||||
return RepositorySettings();
|
return RepositorySettings();
|
||||||
@@ -470,7 +471,7 @@ RepositorySettings FossilClient::synchronousSettingsQuery(const QString &working
|
|||||||
|
|
||||||
const QStringList args("settings");
|
const QStringList args("settings");
|
||||||
|
|
||||||
SynchronousProcess proc;
|
QtcProcess proc;
|
||||||
vcsFullySynchronousExec(proc, workingDirectory, args);
|
vcsFullySynchronousExec(proc, workingDirectory, args);
|
||||||
if (proc.result() != QtcProcess::Finished)
|
if (proc.result() != QtcProcess::Finished)
|
||||||
return RepositorySettings();
|
return RepositorySettings();
|
||||||
@@ -507,7 +508,7 @@ RepositorySettings FossilClient::synchronousSettingsQuery(const QString &working
|
|||||||
return repoSettings;
|
return repoSettings;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool FossilClient::synchronousSetSetting(const QString &workingDirectory,
|
bool FossilClient::synchronousSetSetting(const FilePath &workingDirectory,
|
||||||
const QString &property, const QString &value, bool isGlobal)
|
const QString &property, const QString &value, bool isGlobal)
|
||||||
{
|
{
|
||||||
// set a repository property to the given value
|
// set a repository property to the given value
|
||||||
@@ -525,13 +526,13 @@ bool FossilClient::synchronousSetSetting(const QString &workingDirectory,
|
|||||||
if (isGlobal)
|
if (isGlobal)
|
||||||
args << "--global";
|
args << "--global";
|
||||||
|
|
||||||
SynchronousProcess proc;
|
QtcProcess proc;
|
||||||
vcsFullySynchronousExec(proc, workingDirectory, args);
|
vcsFullySynchronousExec(proc, workingDirectory, args);
|
||||||
return (proc.result() == QtcProcess::Finished);
|
return (proc.result() == QtcProcess::Finished);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
bool FossilClient::synchronousConfigureRepository(const QString &workingDirectory, const RepositorySettings &newSettings,
|
bool FossilClient::synchronousConfigureRepository(const FilePath &workingDirectory, const RepositorySettings &newSettings,
|
||||||
const RepositorySettings ¤tSettings)
|
const RepositorySettings ¤tSettings)
|
||||||
{
|
{
|
||||||
if (workingDirectory.isEmpty())
|
if (workingDirectory.isEmpty())
|
||||||
@@ -575,14 +576,14 @@ bool FossilClient::synchronousConfigureRepository(const QString &workingDirector
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
QString FossilClient::synchronousUserDefaultQuery(const QString &workingDirectory)
|
QString FossilClient::synchronousUserDefaultQuery(const FilePath &workingDirectory)
|
||||||
{
|
{
|
||||||
if (workingDirectory.isEmpty())
|
if (workingDirectory.isEmpty())
|
||||||
return QString();
|
return QString();
|
||||||
|
|
||||||
const QStringList args({"user", "default"});
|
const QStringList args({"user", "default"});
|
||||||
|
|
||||||
SynchronousProcess proc;
|
QtcProcess proc;
|
||||||
vcsFullySynchronousExec(proc, workingDirectory, args);
|
vcsFullySynchronousExec(proc, workingDirectory, args);
|
||||||
if (proc.result() != QtcProcess::Finished)
|
if (proc.result() != QtcProcess::Finished)
|
||||||
return QString();
|
return QString();
|
||||||
@@ -592,26 +593,26 @@ QString FossilClient::synchronousUserDefaultQuery(const QString &workingDirector
|
|||||||
return output.trimmed();
|
return output.trimmed();
|
||||||
}
|
}
|
||||||
|
|
||||||
bool FossilClient::synchronousSetUserDefault(const QString &workingDirectory, const QString &userName)
|
bool FossilClient::synchronousSetUserDefault(const FilePath &workingDirectory, const QString &userName)
|
||||||
{
|
{
|
||||||
if (workingDirectory.isEmpty() || userName.isEmpty())
|
if (workingDirectory.isEmpty() || userName.isEmpty())
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
// set repository-default user
|
// set repository-default user
|
||||||
const QStringList args({"user", "default", userName, "--user", userName});
|
const QStringList args({"user", "default", userName, "--user", userName});
|
||||||
SynchronousProcess proc;
|
QtcProcess proc;
|
||||||
vcsFullySynchronousExec(proc, workingDirectory, args);
|
vcsFullySynchronousExec(proc, workingDirectory, args);
|
||||||
return (proc.result() == QtcProcess::Finished);
|
return (proc.result() == QtcProcess::Finished);
|
||||||
}
|
}
|
||||||
|
|
||||||
QString FossilClient::synchronousGetRepositoryURL(const QString &workingDirectory)
|
QString FossilClient::synchronousGetRepositoryURL(const FilePath &workingDirectory)
|
||||||
{
|
{
|
||||||
if (workingDirectory.isEmpty())
|
if (workingDirectory.isEmpty())
|
||||||
return QString();
|
return QString();
|
||||||
|
|
||||||
const QStringList args("remote-url");
|
const QStringList args("remote-url");
|
||||||
|
|
||||||
SynchronousProcess proc;
|
QtcProcess proc;
|
||||||
vcsFullySynchronousExec(proc, workingDirectory, args);
|
vcsFullySynchronousExec(proc, workingDirectory, args);
|
||||||
if (proc.result() != QtcProcess::Finished)
|
if (proc.result() != QtcProcess::Finished)
|
||||||
return QString();
|
return QString();
|
||||||
@@ -626,7 +627,7 @@ QString FossilClient::synchronousGetRepositoryURL(const QString &workingDirector
|
|||||||
return output;
|
return output;
|
||||||
}
|
}
|
||||||
|
|
||||||
QString FossilClient::synchronousTopic(const QString &workingDirectory)
|
QString FossilClient::synchronousTopic(const FilePath &workingDirectory)
|
||||||
{
|
{
|
||||||
if (workingDirectory.isEmpty())
|
if (workingDirectory.isEmpty())
|
||||||
return QString();
|
return QString();
|
||||||
@@ -640,7 +641,7 @@ QString FossilClient::synchronousTopic(const QString &workingDirectory)
|
|||||||
return branchInfo.name();
|
return branchInfo.name();
|
||||||
}
|
}
|
||||||
|
|
||||||
bool FossilClient::synchronousCreateRepository(const QString &workingDirectory, const QStringList &extraOptions)
|
bool FossilClient::synchronousCreateRepository(const FilePath &workingDirectory, const QStringList &extraOptions)
|
||||||
{
|
{
|
||||||
VcsBase::VcsOutputWindow *outputWindow = VcsBase::VcsOutputWindow::instance();
|
VcsBase::VcsOutputWindow *outputWindow = VcsBase::VcsOutputWindow::instance();
|
||||||
|
|
||||||
@@ -648,7 +649,7 @@ bool FossilClient::synchronousCreateRepository(const QString &workingDirectory,
|
|||||||
// use the configured default repository location for path
|
// use the configured default repository location for path
|
||||||
// use the configured default user for admin
|
// use the configured default user for admin
|
||||||
|
|
||||||
const QString repoName = QDir(workingDirectory).dirName().simplified();
|
const QString repoName = workingDirectory.fileName().simplified();
|
||||||
const QString repoPath = settings().defaultRepoPath.value();
|
const QString repoPath = settings().defaultRepoPath.value();
|
||||||
const QString adminUser = settings().userName.value();
|
const QString adminUser = settings().userName.value();
|
||||||
|
|
||||||
@@ -665,7 +666,7 @@ bool FossilClient::synchronousCreateRepository(const QString &workingDirectory,
|
|||||||
if (!adminUser.isEmpty())
|
if (!adminUser.isEmpty())
|
||||||
args << "--admin-user" << adminUser;
|
args << "--admin-user" << adminUser;
|
||||||
args << extraOptions << repoFilePath.toUserOutput();
|
args << extraOptions << repoFilePath.toUserOutput();
|
||||||
SynchronousProcess proc;
|
QtcProcess proc;
|
||||||
vcsFullySynchronousExec(proc, workingDirectory, args);
|
vcsFullySynchronousExec(proc, workingDirectory, args);
|
||||||
if (proc.result() != QtcProcess::Finished)
|
if (proc.result() != QtcProcess::Finished)
|
||||||
return false;
|
return false;
|
||||||
@@ -706,7 +707,7 @@ bool FossilClient::synchronousCreateRepository(const QString &workingDirectory,
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool FossilClient::synchronousMove(const QString &workingDir,
|
bool FossilClient::synchronousMove(const FilePath &workingDir,
|
||||||
const QString &from, const QString &to,
|
const QString &from, const QString &to,
|
||||||
const QStringList &extraOptions)
|
const QStringList &extraOptions)
|
||||||
{
|
{
|
||||||
@@ -719,12 +720,12 @@ bool FossilClient::synchronousMove(const QString &workingDir,
|
|||||||
|
|
||||||
QStringList args(vcsCommandString(MoveCommand));
|
QStringList args(vcsCommandString(MoveCommand));
|
||||||
args << extraOptions << from << to;
|
args << extraOptions << from << to;
|
||||||
SynchronousProcess proc;
|
QtcProcess proc;
|
||||||
vcsFullySynchronousExec(proc, workingDir, args);
|
vcsFullySynchronousExec(proc, workingDir, args);
|
||||||
return (proc.result() == QtcProcess::Finished);
|
return (proc.result() == QtcProcess::Finished);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool FossilClient::synchronousPull(const QString &workingDir, const QString &srcLocation, const QStringList &extraOptions)
|
bool FossilClient::synchronousPull(const FilePath &workingDir, const QString &srcLocation, const QStringList &extraOptions)
|
||||||
{
|
{
|
||||||
QStringList args(vcsCommandString(PullCommand));
|
QStringList args(vcsCommandString(PullCommand));
|
||||||
if (srcLocation.isEmpty()) {
|
if (srcLocation.isEmpty()) {
|
||||||
@@ -741,15 +742,15 @@ bool FossilClient::synchronousPull(const QString &workingDir, const QString &src
|
|||||||
VcsBase::VcsCommand::SshPasswordPrompt
|
VcsBase::VcsCommand::SshPasswordPrompt
|
||||||
| VcsBase::VcsCommand::ShowStdOut
|
| VcsBase::VcsCommand::ShowStdOut
|
||||||
| VcsBase::VcsCommand::ShowSuccessMessage;
|
| VcsBase::VcsCommand::ShowSuccessMessage;
|
||||||
SynchronousProcess proc;
|
QtcProcess proc;
|
||||||
vcsSynchronousExec(proc, workingDir, args, flags);
|
vcsSynchronousExec(proc, workingDir, args, flags);
|
||||||
const bool success = (proc.result() == QtcProcess::Finished);
|
const bool success = (proc.result() == QtcProcess::Finished);
|
||||||
if (success)
|
if (success)
|
||||||
emit changed(QVariant(workingDir));
|
emit changed(workingDir.toVariant());
|
||||||
return success;
|
return success;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool FossilClient::synchronousPush(const QString &workingDir, const QString &dstLocation, const QStringList &extraOptions)
|
bool FossilClient::synchronousPush(const FilePath &workingDir, const QString &dstLocation, const QStringList &extraOptions)
|
||||||
{
|
{
|
||||||
QStringList args(vcsCommandString(PushCommand));
|
QStringList args(vcsCommandString(PushCommand));
|
||||||
if (dstLocation.isEmpty()) {
|
if (dstLocation.isEmpty()) {
|
||||||
@@ -766,20 +767,19 @@ bool FossilClient::synchronousPush(const QString &workingDir, const QString &dst
|
|||||||
VcsBase::VcsCommand::SshPasswordPrompt
|
VcsBase::VcsCommand::SshPasswordPrompt
|
||||||
| VcsBase::VcsCommand::ShowStdOut
|
| VcsBase::VcsCommand::ShowStdOut
|
||||||
| VcsBase::VcsCommand::ShowSuccessMessage;
|
| VcsBase::VcsCommand::ShowSuccessMessage;
|
||||||
SynchronousProcess proc;
|
QtcProcess proc;
|
||||||
vcsSynchronousExec(proc, workingDir, args, flags);
|
vcsSynchronousExec(proc, workingDir, args, flags);
|
||||||
return (proc.result() == QtcProcess::Finished);
|
return (proc.result() == QtcProcess::Finished);
|
||||||
}
|
}
|
||||||
|
|
||||||
void FossilClient::commit(const QString &repositoryRoot, const QStringList &files,
|
void FossilClient::commit(const FilePath &repositoryRoot, const QStringList &files,
|
||||||
const QString &commitMessageFile, const QStringList &extraOptions)
|
const QString &commitMessageFile, const QStringList &extraOptions)
|
||||||
{
|
{
|
||||||
VcsBaseClient::commit(repositoryRoot, files, commitMessageFile,
|
VcsBaseClient::commit(repositoryRoot, files, commitMessageFile,
|
||||||
QStringList(extraOptions) << "-M" << commitMessageFile);
|
QStringList(extraOptions) << "-M" << commitMessageFile);
|
||||||
}
|
}
|
||||||
|
|
||||||
VcsBase::VcsBaseEditorWidget *FossilClient::annotate(
|
VcsBase::VcsBaseEditorWidget *FossilClient::annotate(const FilePath &workingDir, const QString &file, const QString &revision,
|
||||||
const QString &workingDir, const QString &file, const QString &revision,
|
|
||||||
int lineNumber, const QStringList &extraOptions)
|
int lineNumber, const QStringList &extraOptions)
|
||||||
{
|
{
|
||||||
// 'fossil annotate' command has a variant 'fossil blame'.
|
// 'fossil annotate' command has a variant 'fossil blame'.
|
||||||
@@ -852,10 +852,10 @@ FilePath FossilClient::findTopLevelForFile(const FilePath &file) const
|
|||||||
return VcsBase::findRepositoryForFile(file, Constants::FOSSILREPO);
|
return VcsBase::findRepositoryForFile(file, Constants::FOSSILREPO);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool FossilClient::managesFile(const QString &workingDirectory, const QString &fileName) const
|
bool FossilClient::managesFile(const FilePath &workingDirectory, const QString &fileName) const
|
||||||
{
|
{
|
||||||
const QStringList args({"finfo", fileName});
|
const QStringList args({"finfo", fileName});
|
||||||
SynchronousProcess proc;
|
QtcProcess proc;
|
||||||
vcsFullySynchronousExec(proc, workingDirectory, args);
|
vcsFullySynchronousExec(proc, workingDirectory, args);
|
||||||
if (proc.result() != QtcProcess::Finished)
|
if (proc.result() != QtcProcess::Finished)
|
||||||
return false;
|
return false;
|
||||||
@@ -927,8 +927,8 @@ void FossilClient::view(const QString &source, const QString &id, const QStringL
|
|||||||
{
|
{
|
||||||
QStringList args("diff");
|
QStringList args("diff");
|
||||||
|
|
||||||
const QFileInfo fi(source);
|
const FilePath fPath = FilePath::fromString(source);
|
||||||
const QString workingDirectory = fi.isFile() ? fi.absolutePath() : source;
|
const FilePath workingDirectory = fPath.isFile() ? fPath.absolutePath() : fPath;
|
||||||
|
|
||||||
RevisionInfo revisionInfo = synchronousRevisionQuery(workingDirectory,id);
|
RevisionInfo revisionInfo = synchronousRevisionQuery(workingDirectory,id);
|
||||||
|
|
||||||
@@ -992,7 +992,7 @@ void FossilLogHighlighter::highlightBlock(const QString &text)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void FossilClient::log(const QString &workingDir, const QStringList &files,
|
void FossilClient::log(const FilePath &workingDir, const QStringList &files,
|
||||||
const QStringList &extraOptions,
|
const QStringList &extraOptions,
|
||||||
bool enableAnnotationContextMenu)
|
bool enableAnnotationContextMenu)
|
||||||
{
|
{
|
||||||
@@ -1045,7 +1045,7 @@ void FossilClient::log(const QString &workingDir, const QStringList &files,
|
|||||||
enqueueJob(createCommand(workingDir, fossilEditor), args);
|
enqueueJob(createCommand(workingDir, fossilEditor), args);
|
||||||
}
|
}
|
||||||
|
|
||||||
void FossilClient::logCurrentFile(const QString &workingDir, const QStringList &files,
|
void FossilClient::logCurrentFile(const FilePath &workingDir, const QStringList &files,
|
||||||
const QStringList &extraOptions,
|
const QStringList &extraOptions,
|
||||||
bool enableAnnotationContextMenu)
|
bool enableAnnotationContextMenu)
|
||||||
{
|
{
|
||||||
@@ -1095,7 +1095,7 @@ void FossilClient::logCurrentFile(const QString &workingDir, const QStringList &
|
|||||||
enqueueJob(createCommand(workingDir, fossilEditor), args);
|
enqueueJob(createCommand(workingDir, fossilEditor), args);
|
||||||
}
|
}
|
||||||
|
|
||||||
void FossilClient::revertFile(const QString &workingDir,
|
void FossilClient::revertFile(const FilePath &workingDir,
|
||||||
const QString &file,
|
const QString &file,
|
||||||
const QString &revision,
|
const QString &revision,
|
||||||
const QStringList &extraOptions)
|
const QStringList &extraOptions)
|
||||||
@@ -1108,12 +1108,12 @@ void FossilClient::revertFile(const QString &workingDir,
|
|||||||
|
|
||||||
// Indicate file list
|
// Indicate file list
|
||||||
VcsBase::VcsCommand *cmd = createCommand(workingDir);
|
VcsBase::VcsCommand *cmd = createCommand(workingDir);
|
||||||
cmd->setCookie(QStringList(workingDir + "/" + file));
|
cmd->setCookie(QStringList(workingDir.toString() + "/" + file));
|
||||||
connect(cmd, &VcsBase::VcsCommand::success, this, &VcsBase::VcsBaseClient::changed, Qt::QueuedConnection);
|
connect(cmd, &VcsBase::VcsCommand::success, this, &VcsBase::VcsBaseClient::changed, Qt::QueuedConnection);
|
||||||
enqueueJob(cmd, args);
|
enqueueJob(cmd, args);
|
||||||
}
|
}
|
||||||
|
|
||||||
void FossilClient::revertAll(const QString &workingDir, const QString &revision, const QStringList &extraOptions)
|
void FossilClient::revertAll(const FilePath &workingDir, const QString &revision, const QStringList &extraOptions)
|
||||||
{
|
{
|
||||||
// Fossil allows whole tree revert to latest revision (effectively undoing uncommitted changes).
|
// Fossil allows whole tree revert to latest revision (effectively undoing uncommitted changes).
|
||||||
// However it disallows revert to a specific revision for the whole tree, only for selected files.
|
// However it disallows revert to a specific revision for the whole tree, only for selected files.
|
||||||
@@ -1134,7 +1134,7 @@ void FossilClient::revertAll(const QString &workingDir, const QString &revision,
|
|||||||
|
|
||||||
// Indicate repository change
|
// Indicate repository change
|
||||||
VcsBase::VcsCommand *cmd = createCommand(workingDir);
|
VcsBase::VcsCommand *cmd = createCommand(workingDir);
|
||||||
cmd->setCookie(QStringList(workingDir));
|
cmd->setCookie(QStringList(workingDir.toString()));
|
||||||
connect(cmd, &VcsBase::VcsCommand::success, this, &VcsBase::VcsBaseClient::changed, Qt::QueuedConnection);
|
connect(cmd, &VcsBase::VcsCommand::success, this, &VcsBase::VcsBaseClient::changed, Qt::QueuedConnection);
|
||||||
enqueueJob(createCommand(workingDir), args);
|
enqueueJob(createCommand(workingDir), args);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -67,50 +67,51 @@ public:
|
|||||||
FossilSettings &settings() const;
|
FossilSettings &settings() const;
|
||||||
|
|
||||||
unsigned int synchronousBinaryVersion() const;
|
unsigned int synchronousBinaryVersion() const;
|
||||||
BranchInfo synchronousCurrentBranch(const QString &workingDirectory);
|
BranchInfo synchronousCurrentBranch(const Utils::FilePath &workingDirectory);
|
||||||
QList<BranchInfo> synchronousBranchQuery(const QString &workingDirectory);
|
QList<BranchInfo> synchronousBranchQuery(const Utils::FilePath &workingDirectory);
|
||||||
RevisionInfo synchronousRevisionQuery(const QString &workingDirectory, const QString &id = QString(),
|
RevisionInfo synchronousRevisionQuery(const Utils::FilePath &workingDirectory,
|
||||||
|
const QString &id = QString(),
|
||||||
bool getCommentMsg = false) const;
|
bool getCommentMsg = false) const;
|
||||||
QStringList synchronousTagQuery(const QString &workingDirectory, const QString &id = QString());
|
QStringList synchronousTagQuery(const Utils::FilePath &workingDirectory, const QString &id = {});
|
||||||
RepositorySettings synchronousSettingsQuery(const QString &workingDirectory);
|
RepositorySettings synchronousSettingsQuery(const Utils::FilePath &workingDirectory);
|
||||||
bool synchronousSetSetting(const QString &workingDirectory, const QString &property,
|
bool synchronousSetSetting(const Utils::FilePath &workingDirectory, const QString &property,
|
||||||
const QString &value = QString(), bool isGlobal = false);
|
const QString &value = QString(), bool isGlobal = false);
|
||||||
bool synchronousConfigureRepository(const QString &workingDirectory, const RepositorySettings &newSettings,
|
bool synchronousConfigureRepository(const Utils::FilePath &workingDirectory, const RepositorySettings &newSettings,
|
||||||
const RepositorySettings ¤tSettings = RepositorySettings());
|
const RepositorySettings ¤tSettings = RepositorySettings());
|
||||||
QString synchronousUserDefaultQuery(const QString &workingDirectory);
|
QString synchronousUserDefaultQuery(const Utils::FilePath &workingDirectory);
|
||||||
bool synchronousSetUserDefault(const QString &workingDirectory, const QString &userName);
|
bool synchronousSetUserDefault(const Utils::FilePath &workingDirectory, const QString &userName);
|
||||||
QString synchronousGetRepositoryURL(const QString &workingDirectory);
|
QString synchronousGetRepositoryURL(const Utils::FilePath &workingDirectory);
|
||||||
QString synchronousTopic(const QString &workingDirectory);
|
QString synchronousTopic(const Utils::FilePath &workingDirectory);
|
||||||
bool synchronousCreateRepository(const QString &workingDirectory,
|
bool synchronousCreateRepository(const Utils::FilePath &workingDirectory,
|
||||||
const QStringList &extraOptions = QStringList()) final;
|
const QStringList &extraOptions = QStringList()) final;
|
||||||
bool synchronousMove(const QString &workingDir,
|
bool synchronousMove(const Utils::FilePath &workingDir,
|
||||||
const QString &from, const QString &to,
|
const QString &from, const QString &to,
|
||||||
const QStringList &extraOptions = QStringList()) final;
|
const QStringList &extraOptions = QStringList()) final;
|
||||||
bool synchronousPull(const QString &workingDir,
|
bool synchronousPull(const Utils::FilePath &workingDir,
|
||||||
const QString &srcLocation,
|
const QString &srcLocation,
|
||||||
const QStringList &extraOptions = QStringList()) final;
|
const QStringList &extraOptions = QStringList()) final;
|
||||||
bool synchronousPush(const QString &workingDir,
|
bool synchronousPush(const Utils::FilePath &workingDir,
|
||||||
const QString &dstLocation,
|
const QString &dstLocation,
|
||||||
const QStringList &extraOptions = QStringList()) final;
|
const QStringList &extraOptions = QStringList()) final;
|
||||||
void commit(const QString &repositoryRoot, const QStringList &files,
|
void commit(const Utils::FilePath &repositoryRoot, const QStringList &files,
|
||||||
const QString &commitMessageFile, const QStringList &extraOptions = QStringList()) final;
|
const QString &commitMessageFile, const QStringList &extraOptions = QStringList()) final;
|
||||||
VcsBase::VcsBaseEditorWidget *annotate(
|
VcsBase::VcsBaseEditorWidget *annotate(
|
||||||
const QString &workingDir, const QString &file, const QString &revision = QString(),
|
const Utils::FilePath &workingDir, const QString &file, const QString &revision = {},
|
||||||
int lineNumber = -1, const QStringList &extraOptions = QStringList()) final;
|
int lineNumber = -1, const QStringList &extraOptions = QStringList()) final;
|
||||||
void log(const QString &workingDir, const QStringList &files = QStringList(),
|
void log(const Utils::FilePath &workingDir, const QStringList &files = QStringList(),
|
||||||
const QStringList &extraOptions = QStringList(),
|
const QStringList &extraOptions = QStringList(),
|
||||||
bool enableAnnotationContextMenu = false) final;
|
bool enableAnnotationContextMenu = false) final;
|
||||||
void logCurrentFile(const QString &workingDir, const QStringList &files = QStringList(),
|
void logCurrentFile(const Utils::FilePath &workingDir, const QStringList &files = QStringList(),
|
||||||
const QStringList &extraOptions = QStringList(),
|
const QStringList &extraOptions = QStringList(),
|
||||||
bool enableAnnotationContextMenu = false);
|
bool enableAnnotationContextMenu = false);
|
||||||
void revertFile(const QString &workingDir, const QString &file,
|
void revertFile(const Utils::FilePath &workingDir, const QString &file,
|
||||||
const QString &revision = QString(),
|
const QString &revision = QString(),
|
||||||
const QStringList &extraOptions = QStringList()) final;
|
const QStringList &extraOptions = QStringList()) final;
|
||||||
void revertAll(const QString &workingDir, const QString &revision = QString(),
|
void revertAll(const Utils::FilePath &workingDir, const QString &revision = QString(),
|
||||||
const QStringList &extraOptions = QStringList()) final;
|
const QStringList &extraOptions = QStringList()) final;
|
||||||
bool isVcsFileOrDirectory(const Utils::FilePath &filePath) const;
|
bool isVcsFileOrDirectory(const Utils::FilePath &filePath) const;
|
||||||
Utils::FilePath findTopLevelForFile(const Utils::FilePath &file) const final;
|
Utils::FilePath findTopLevelForFile(const Utils::FilePath &file) const final;
|
||||||
bool managesFile(const QString &workingDirectory, const QString &fileName) const;
|
bool managesFile(const Utils::FilePath &workingDirectory, const QString &fileName) const;
|
||||||
unsigned int binaryVersion() const;
|
unsigned int binaryVersion() const;
|
||||||
QString binaryVersionString() const;
|
QString binaryVersionString() const;
|
||||||
SupportedFeatures supportedFeatures() const;
|
SupportedFeatures supportedFeatures() const;
|
||||||
|
|||||||
@@ -90,8 +90,7 @@ QString FossilEditorWidget::decorateVersion(const QString &revision) const
|
|||||||
static const int shortChangesetIdSize(10);
|
static const int shortChangesetIdSize(10);
|
||||||
static const int maxTextSize(120);
|
static const int maxTextSize(120);
|
||||||
|
|
||||||
const QFileInfo fi(source());
|
const Utils::FilePath workingDirectory = Utils::FilePath::fromString(source()).parentDir();
|
||||||
const QString workingDirectory = fi.absolutePath();
|
|
||||||
const FossilClient *client = FossilPlugin::client();
|
const FossilClient *client = FossilPlugin::client();
|
||||||
RevisionInfo revisionInfo =
|
RevisionInfo revisionInfo =
|
||||||
client->synchronousRevisionQuery(workingDirectory, revision, true);
|
client->synchronousRevisionQuery(workingDirectory, revision, true);
|
||||||
@@ -112,8 +111,7 @@ QString FossilEditorWidget::decorateVersion(const QString &revision) const
|
|||||||
QStringList FossilEditorWidget::annotationPreviousVersions(const QString &revision) const
|
QStringList FossilEditorWidget::annotationPreviousVersions(const QString &revision) const
|
||||||
{
|
{
|
||||||
QStringList revisions;
|
QStringList revisions;
|
||||||
const QFileInfo fi(source());
|
const Utils::FilePath workingDirectory = Utils::FilePath::fromString(source()).parentDir();
|
||||||
const QString workingDirectory = fi.absolutePath();
|
|
||||||
const FossilClient *client = FossilPlugin::client();
|
const FossilClient *client = FossilPlugin::client();
|
||||||
RevisionInfo revisionInfo =
|
RevisionInfo revisionInfo =
|
||||||
client->synchronousRevisionQuery(workingDirectory, revision);
|
client->synchronousRevisionQuery(workingDirectory, revision);
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ namespace Internal {
|
|||||||
|
|
||||||
class FossilEditorWidgetPrivate;
|
class FossilEditorWidgetPrivate;
|
||||||
|
|
||||||
class FossilEditorWidget : public VcsBase::VcsBaseEditorWidget
|
class FossilEditorWidget final : public VcsBase::VcsBaseEditorWidget
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
|
|||||||
@@ -96,7 +96,7 @@ protected:
|
|||||||
|
|
||||||
QString refreshTopic(const FilePath &repository) final
|
QString refreshTopic(const FilePath &repository) final
|
||||||
{
|
{
|
||||||
return m_client->synchronousTopic(repository.toString());
|
return m_client->synchronousTopic(repository);
|
||||||
}
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
@@ -255,7 +255,7 @@ public:
|
|||||||
// Submit editor actions
|
// Submit editor actions
|
||||||
QAction *m_menuAction = nullptr;
|
QAction *m_menuAction = nullptr;
|
||||||
|
|
||||||
QString m_submitRepository;
|
Utils::FilePath m_submitRepository;
|
||||||
bool m_submitActionTriggered = false;
|
bool m_submitActionTriggered = false;
|
||||||
|
|
||||||
// To be connected to the VcsTask's success signal to emit the repository/
|
// To be connected to the VcsTask's success signal to emit the repository/
|
||||||
@@ -729,8 +729,7 @@ void FossilPluginPrivate::showCommitWidget(const QList<VcsBase::VcsBaseClient::S
|
|||||||
}
|
}
|
||||||
setSubmitEditor(commitEditor);
|
setSubmitEditor(commitEditor);
|
||||||
|
|
||||||
const QString msg = tr("Commit changes for \"%1\".").
|
const QString msg = tr("Commit changes for \"%1\".").arg(m_submitRepository.toUserOutput());
|
||||||
arg(QDir::toNativeSeparators(m_submitRepository));
|
|
||||||
commitEditor->document()->setPreferredDisplayName(msg);
|
commitEditor->document()->setPreferredDisplayName(msg);
|
||||||
|
|
||||||
const RevisionInfo currentRevision = m_client.synchronousRevisionQuery(m_submitRepository);
|
const RevisionInfo currentRevision = m_client.synchronousRevisionQuery(m_submitRepository);
|
||||||
@@ -739,7 +738,7 @@ void FossilPluginPrivate::showCommitWidget(const QList<VcsBase::VcsBaseClient::S
|
|||||||
QStringList tags = m_client.synchronousTagQuery(m_submitRepository, currentRevision.id);
|
QStringList tags = m_client.synchronousTagQuery(m_submitRepository, currentRevision.id);
|
||||||
// Fossil includes branch name in tag list -- remove.
|
// Fossil includes branch name in tag list -- remove.
|
||||||
tags.removeAll(currentBranch.name());
|
tags.removeAll(currentBranch.name());
|
||||||
commitEditor->setFields(m_submitRepository, currentBranch, tags, currentUser, status);
|
commitEditor->setFields(m_submitRepository.toString(), currentBranch, tags, currentUser, status);
|
||||||
|
|
||||||
connect(commitEditor, &VcsBase::VcsBaseSubmitEditor::diffSelectedFiles,
|
connect(commitEditor, &VcsBase::VcsBaseSubmitEditor::diffSelectedFiles,
|
||||||
this, &FossilPluginPrivate::diffFromEditorSelected);
|
this, &FossilPluginPrivate::diffFromEditorSelected);
|
||||||
@@ -763,27 +762,27 @@ void FossilPluginPrivate::createRepository()
|
|||||||
// re-implemented from void VcsBasePlugin::createRepository()
|
// re-implemented from void VcsBasePlugin::createRepository()
|
||||||
|
|
||||||
// Find current starting directory
|
// Find current starting directory
|
||||||
QString directory;
|
Utils::FilePath directory;
|
||||||
if (const ProjectExplorer::Project *currentProject = ProjectExplorer::ProjectTree::currentProject())
|
if (const ProjectExplorer::Project *currentProject = ProjectExplorer::ProjectTree::currentProject())
|
||||||
directory = currentProject->projectDirectory().toString();
|
directory = currentProject->projectDirectory();
|
||||||
// Prompt for a directory that is not under version control yet
|
// Prompt for a directory that is not under version control yet
|
||||||
QWidget *mw = Core::ICore::mainWindow();
|
QWidget *mw = Core::ICore::mainWindow();
|
||||||
do {
|
do {
|
||||||
directory = QFileDialog::getExistingDirectory(mw, tr("Choose Checkout Directory"), directory);
|
directory = FileUtils::getExistingDirectory(tr("Choose Checkout Directory"), directory);
|
||||||
if (directory.isEmpty())
|
if (directory.isEmpty())
|
||||||
return;
|
return;
|
||||||
const Core::IVersionControl *managingControl = Core::VcsManager::findVersionControlForDirectory(directory);
|
const Core::IVersionControl *managingControl = Core::VcsManager::findVersionControlForDirectory(directory);
|
||||||
if (managingControl == 0)
|
if (managingControl == 0)
|
||||||
break;
|
break;
|
||||||
const QString question = tr("The directory \"%1\" is already managed by a version control system (%2)."
|
const QString question = tr("The directory \"%1\" is already managed by a version control system (%2)."
|
||||||
" Would you like to specify another directory?").arg(directory, managingControl->displayName());
|
" Would you like to specify another directory?").arg(directory.toUserOutput(), managingControl->displayName());
|
||||||
|
|
||||||
if (!ask(mw, tr("Repository already under version control"), question))
|
if (!ask(mw, tr("Repository already under version control"), question))
|
||||||
return;
|
return;
|
||||||
} while (true);
|
} while (true);
|
||||||
// Create
|
// Create
|
||||||
const bool rc = vcsCreateRepository(FilePath::fromString(directory));
|
const bool rc = vcsCreateRepository(directory);
|
||||||
const QString nativeDir = QDir::toNativeSeparators(directory);
|
const QString nativeDir = directory.toUserOutput();
|
||||||
if (rc) {
|
if (rc) {
|
||||||
QMessageBox::information(mw, tr("Repository Created"),
|
QMessageBox::information(mw, tr("Repository Created"),
|
||||||
tr("A version control repository has been created in %1.").
|
tr("A version control repository has been created in %1.").
|
||||||
@@ -915,7 +914,7 @@ bool FossilPluginPrivate::managesDirectory(const FilePath &directory, FilePath *
|
|||||||
|
|
||||||
bool FossilPluginPrivate::managesFile(const FilePath &workingDirectory, const QString &fileName) const
|
bool FossilPluginPrivate::managesFile(const FilePath &workingDirectory, const QString &fileName) const
|
||||||
{
|
{
|
||||||
return m_client.managesFile(workingDirectory.toString(), fileName);
|
return m_client.managesFile(workingDirectory, fileName);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool FossilPluginPrivate::isConfigured() const
|
bool FossilPluginPrivate::isConfigured() const
|
||||||
@@ -967,34 +966,31 @@ bool FossilPluginPrivate::vcsOpen(const FilePath &filePath)
|
|||||||
|
|
||||||
bool FossilPluginPrivate::vcsAdd(const FilePath &filePath)
|
bool FossilPluginPrivate::vcsAdd(const FilePath &filePath)
|
||||||
{
|
{
|
||||||
const QFileInfo fi = filePath.toFileInfo();
|
return m_client.synchronousAdd(filePath.absolutePath(), filePath.fileName());
|
||||||
return m_client.synchronousAdd(fi.absolutePath(), fi.fileName());
|
|
||||||
}
|
}
|
||||||
|
|
||||||
bool FossilPluginPrivate::vcsDelete(const FilePath &filePath)
|
bool FossilPluginPrivate::vcsDelete(const FilePath &filePath)
|
||||||
{
|
{
|
||||||
const QFileInfo fi = filePath.toFileInfo();
|
return m_client.synchronousRemove(filePath.absolutePath(), filePath.fileName());
|
||||||
return m_client.synchronousRemove(fi.absolutePath(), fi.fileName());
|
|
||||||
}
|
}
|
||||||
|
|
||||||
bool FossilPluginPrivate::vcsMove(const FilePath &from, const FilePath &to)
|
bool FossilPluginPrivate::vcsMove(const FilePath &from, const FilePath &to)
|
||||||
{
|
{
|
||||||
const QFileInfo fromInfo = from.toFileInfo();
|
const QFileInfo fromInfo = from.toFileInfo();
|
||||||
const QFileInfo toInfo = to.toFileInfo();
|
const QFileInfo toInfo = to.toFileInfo();
|
||||||
return m_client.synchronousMove(fromInfo.absolutePath(),
|
return m_client.synchronousMove(from.absolutePath(),
|
||||||
fromInfo.absoluteFilePath(),
|
fromInfo.absoluteFilePath(),
|
||||||
toInfo.absoluteFilePath());
|
toInfo.absoluteFilePath());
|
||||||
}
|
}
|
||||||
|
|
||||||
bool FossilPluginPrivate::vcsCreateRepository(const FilePath &directory)
|
bool FossilPluginPrivate::vcsCreateRepository(const FilePath &directory)
|
||||||
{
|
{
|
||||||
return m_client.synchronousCreateRepository(directory.toString());
|
return m_client.synchronousCreateRepository(directory);
|
||||||
}
|
}
|
||||||
|
|
||||||
void FossilPluginPrivate::vcsAnnotate(const FilePath &filePath, int line)
|
void FossilPluginPrivate::vcsAnnotate(const FilePath &filePath, int line)
|
||||||
{
|
{
|
||||||
const QFileInfo fi = filePath.toFileInfo();
|
m_client.annotate(filePath.absolutePath(), filePath.fileName(), QString(), line);
|
||||||
m_client.annotate(fi.absolutePath(), fi.fileName(), QString(), line);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void FossilPluginPrivate::vcsDescribe(const FilePath &source, const QString &id) { m_client.view(source.toString(), id); }
|
void FossilPluginPrivate::vcsDescribe(const FilePath &source, const QString &id) { m_client.view(source.toString(), id); }
|
||||||
@@ -1018,7 +1014,7 @@ Core::ShellCommand *FossilPluginPrivate::createInitialCheckoutCommand(const QStr
|
|||||||
// -- open/checkout an existing local fossil
|
// -- open/checkout an existing local fossil
|
||||||
// Clone URL is an absolute local path and is the same as the local fossil.
|
// Clone URL is an absolute local path and is the same as the local fossil.
|
||||||
|
|
||||||
const QString checkoutPath = baseDirectory.pathAppended(localName).toString();
|
const Utils::FilePath checkoutPath = baseDirectory.pathAppended(localName);
|
||||||
const QString fossilFile = options.value("fossil-file");
|
const QString fossilFile = options.value("fossil-file");
|
||||||
const Utils::FilePath fossilFilePath = Utils::FilePath::fromUserInput(QDir::fromNativeSeparators(fossilFile));
|
const Utils::FilePath fossilFilePath = Utils::FilePath::fromUserInput(QDir::fromNativeSeparators(fossilFile));
|
||||||
const QString fossilFileNative = fossilFilePath.toUserOutput();
|
const QString fossilFileNative = fossilFilePath.toUserOutput();
|
||||||
@@ -1043,12 +1039,10 @@ Core::ShellCommand *FossilPluginPrivate::createInitialCheckoutCommand(const QStr
|
|||||||
|
|
||||||
// first create the checkout directory,
|
// first create the checkout directory,
|
||||||
// as it needs to become a working directory for wizard command jobs
|
// as it needs to become a working directory for wizard command jobs
|
||||||
|
checkoutPath.createDir();
|
||||||
const QDir checkoutDir(checkoutPath);
|
|
||||||
checkoutDir.mkpath(checkoutPath);
|
|
||||||
|
|
||||||
// Setup the wizard page command job
|
// Setup the wizard page command job
|
||||||
auto command = new VcsBase::VcsCommand(checkoutDir.path(), m_client.processEnvironment());
|
auto command = new VcsBase::VcsCommand(checkoutPath, m_client.processEnvironment());
|
||||||
|
|
||||||
if (!isLocalRepository
|
if (!isLocalRepository
|
||||||
&& !cloneRepository.exists()) {
|
&& !cloneRepository.exists()) {
|
||||||
@@ -1116,7 +1110,7 @@ void FossilPluginPrivate::changed(const QVariant &v)
|
|||||||
{
|
{
|
||||||
switch (v.type()) {
|
switch (v.type()) {
|
||||||
case QVariant::String:
|
case QVariant::String:
|
||||||
emit repositoryChanged(v.toString());
|
emit repositoryChanged(Utils::FilePath::fromVariant(v));
|
||||||
break;
|
break;
|
||||||
case QVariant::StringList:
|
case QVariant::StringList:
|
||||||
emit filesChanged(v.toStringList());
|
emit filesChanged(v.toStringList());
|
||||||
|
|||||||
Reference in New Issue
Block a user