VcsBase: Rename vcsFullySynchronousExec into vcsSynchronousExec

Get rid of original vcsSynchronousExec(), as it was calling
vcsFullySynchronousExec().

Change-Id: I911dc786d54c34c211d03661c37df9b58d60a20b
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
This commit is contained in:
Jarek Kobus
2022-09-02 15:12:13 +02:00
parent 996e1bfc45
commit 6d6346044c
8 changed files with 67 additions and 83 deletions

View File

@@ -119,13 +119,13 @@ QString VcsBaseClientImpl::stripLastNewline(const QString &in)
return in;
}
CommandResult VcsBaseClientImpl::vcsFullySynchronousExec(const FilePath &workingDir,
CommandResult VcsBaseClientImpl::vcsSynchronousExec(const FilePath &workingDir,
const QStringList &args, unsigned flags, int timeoutS, QTextCodec *codec) const
{
return vcsFullySynchronousExec(workingDir, {vcsBinary(), args}, flags, timeoutS, codec);
return vcsSynchronousExec(workingDir, {vcsBinary(), args}, flags, timeoutS, codec);
}
CommandResult VcsBaseClientImpl::vcsFullySynchronousExec(const FilePath &workingDir,
CommandResult VcsBaseClientImpl::vcsSynchronousExec(const FilePath &workingDir,
const CommandLine &cmdLine, unsigned flags, int timeoutS, QTextCodec *codec) const
{
VcsCommand command(workingDir, processEnvironment());
@@ -167,14 +167,6 @@ VcsCommand *VcsBaseClientImpl::vcsExec(const FilePath &workingDirectory,
return command;
}
CommandResult VcsBaseClientImpl::vcsSynchronousExec(const FilePath &workingDir,
const QStringList &args,
unsigned flags,
QTextCodec *outputCodec) const
{
return vcsFullySynchronousExec(workingDir, args, flags, vcsTimeoutS(), outputCodec);
}
int VcsBaseClientImpl::vcsTimeoutS() const
{
return m_baseSettings->timeout.value();
@@ -232,7 +224,7 @@ bool VcsBaseClient::synchronousCreateRepository(const FilePath &workingDirectory
{
QStringList args(vcsCommandString(CreateRepositoryCommand));
args << extraOptions;
const CommandResult result = vcsFullySynchronousExec(workingDirectory, args);
const CommandResult result = vcsSynchronousExec(workingDirectory, args);
if (result.result() != ProcessResult::FinishedWithSuccess)
return false;
VcsOutputWindow::append(result.cleanedStdOut());
@@ -251,7 +243,7 @@ bool VcsBaseClient::synchronousClone(const FilePath &workingDir,
args << vcsCommandString(CloneCommand)
<< extraOptions << srcLocation << dstLocation;
const CommandResult result = vcsFullySynchronousExec(workingDir, args);
const CommandResult result = vcsSynchronousExec(workingDir, args);
resetCachedVcsInfo(workingDir);
return result.result() == ProcessResult::FinishedWithSuccess;
}
@@ -262,7 +254,7 @@ bool VcsBaseClient::synchronousAdd(const FilePath &workingDir,
{
QStringList args;
args << vcsCommandString(AddCommand) << extraOptions << relFileName;
return vcsFullySynchronousExec(workingDir, args).result() == ProcessResult::FinishedWithSuccess;
return vcsSynchronousExec(workingDir, args).result() == ProcessResult::FinishedWithSuccess;
}
bool VcsBaseClient::synchronousRemove(const FilePath &workingDir,
@@ -271,7 +263,7 @@ bool VcsBaseClient::synchronousRemove(const FilePath &workingDir,
{
QStringList args;
args << vcsCommandString(RemoveCommand) << extraOptions << filename;
return vcsFullySynchronousExec(workingDir, args).result() == ProcessResult::FinishedWithSuccess;
return vcsSynchronousExec(workingDir, args).result() == ProcessResult::FinishedWithSuccess;
}
bool VcsBaseClient::synchronousMove(const FilePath &workingDir,
@@ -281,7 +273,7 @@ bool VcsBaseClient::synchronousMove(const FilePath &workingDir,
{
QStringList args;
args << vcsCommandString(MoveCommand) << extraOptions << from << to;
return vcsFullySynchronousExec(workingDir, args).result() == ProcessResult::FinishedWithSuccess;
return vcsSynchronousExec(workingDir, args).result() == ProcessResult::FinishedWithSuccess;
}
bool VcsBaseClient::synchronousPull(const FilePath &workingDir,