[eel-vcs] using eel external cli api:

update implementation classes to use the new constructor

GitOrigin-RevId: c1b3bc2499c74cf21724170cb19bb29a3046f407
This commit is contained in:
Mihail Buryakov
2025-05-30 01:10:09 +03:00
committed by intellij-monorepo-bot
parent c3a9fe8834
commit 0d03a42d44
6 changed files with 31 additions and 7 deletions

View File

@@ -32,7 +32,7 @@ a:com.intellij.externalProcessAuthHelper.ExternalProcessRest
f:com.intellij.externalProcessAuthHelper.NativeSshAuthService
- com.intellij.externalProcessAuthHelper.ExternalProcessHandlerService
- sf:Companion:com.intellij.externalProcessAuthHelper.NativeSshAuthService$Companion
- <init>():V
- <init>(kotlinx.coroutines.CoroutineScope):V
- sf:getInstance():com.intellij.externalProcessAuthHelper.NativeSshAuthService
f:com.intellij.externalProcessAuthHelper.NativeSshAuthService$Companion
- f:getInstance():com.intellij.externalProcessAuthHelper.NativeSshAuthService

View File

@@ -5,11 +5,17 @@ import com.intellij.openapi.components.Service
import com.intellij.openapi.components.service
import externalApp.nativessh.NativeSshAskPassApp
import externalApp.nativessh.NativeSshAskPassAppHandler
import kotlinx.coroutines.CoroutineScope
@Service(Service.Level.APP)
class NativeSshAuthService : ExternalProcessHandlerService<NativeSshAskPassAppHandler>(
class NativeSshAuthService(
coroutineScope: CoroutineScope
) : ExternalProcessHandlerService<NativeSshAskPassAppHandler>(
"intellij-ssh-askpass",
NativeSshAskPassApp::class.java
NativeSshAskPassApp::class.java,
null,
listOf(NativeSshAskPassAppHandler.IJ_SSH_ASK_PASS_HANDLER_ENV, NativeSshAskPassAppHandler.IJ_SSH_ASK_PASS_PORT_ENV),
coroutineScope
) {
companion object {
@JvmStatic

View File

@@ -12,15 +12,19 @@ import com.intellij.openapi.project.Project
import com.intellij.openapi.util.text.StringUtilRt
import git4idea.http.GitAskPassApp
import git4idea.http.GitAskPassAppHandler
import kotlinx.coroutines.CoroutineScope
import java.io.File
import java.util.*
/**
* Provides the authentication mechanism for Git HTTP connections.
*/
abstract class GitHttpAuthService : ExternalProcessHandlerService<GitAskPassAppHandler>(
abstract class GitHttpAuthService(coroutineScope: CoroutineScope) : ExternalProcessHandlerService<GitAskPassAppHandler>(
"intellij-git-askpass",
GitAskPassApp::class.java
GitAskPassApp::class.java,
GitAskPassApp(),
listOf(GitAskPassAppHandler.IJ_ASK_PASS_HANDLER_ENV, GitAskPassAppHandler.IJ_ASK_PASS_PORT_ENV),
coroutineScope
) {
/**
* Creates new [GitHttpAuthenticator] that will be requested to handle username and password requests from Git.

View File

@@ -4,12 +4,16 @@ package git4idea.commands;
import com.intellij.externalProcessAuthHelper.AuthenticationGate;
import com.intellij.externalProcessAuthHelper.AuthenticationMode;
import com.intellij.openapi.project.Project;
import kotlinx.coroutines.CoroutineScope;
import org.jetbrains.annotations.NotNull;
import java.io.File;
import java.util.Collection;
class GitHttpAuthServiceImpl extends GitHttpAuthService {
GitHttpAuthServiceImpl(CoroutineScope coroutineScope) {
super(coroutineScope);
}
@Override
public @NotNull GitHttpGuiAuthenticator createAuthenticator(@NotNull Project project,

View File

@@ -9,13 +9,19 @@ import com.intellij.openapi.components.service
import git4idea.config.GitExecutable
import git4idea.editor.GitRebaseEditorApp
import git4idea.editor.GitRebaseEditorAppHandler
import kotlinx.coroutines.CoroutineScope
import java.util.*
import kotlin.io.path.Path
@Service(Service.Level.APP)
internal class GitRebaseEditorService : ExternalProcessHandlerService<GitRebaseEditorAppHandler>(
internal class GitRebaseEditorService(
coroutineScope: CoroutineScope
) : ExternalProcessHandlerService<GitRebaseEditorAppHandler>(
"intellij-git-editor",
GitRebaseEditorApp::class.java
GitRebaseEditorApp::class.java,
GitRebaseEditorApp(),
listOf(GitRebaseEditorAppHandler.IJ_EDITOR_HANDLER_ENV, GitRebaseEditorAppHandler.IJ_EDITOR_PORT_ENV),
coroutineScope
) {
companion object {
@JvmStatic

View File

@@ -20,12 +20,16 @@ import com.intellij.externalProcessAuthHelper.AuthenticationMode;
import com.intellij.openapi.project.Project;
import git4idea.commands.GitHttpAuthService;
import git4idea.commands.GitHttpAuthenticator;
import kotlinx.coroutines.CoroutineScope;
import org.jetbrains.annotations.NotNull;
import java.io.File;
import java.util.Collection;
public class GitHttpAuthTestService extends GitHttpAuthService {
GitHttpAuthTestService(CoroutineScope coroutineScope) {
super(coroutineScope);
}
@NotNull private GitHttpAuthenticator myAuthenticator = STUB_AUTHENTICATOR;