mirror of
https://github.com/chriswritescode-dev/opencode-manager.git
synced 2026-12-06 04:44:21 +01:00
Add skip SSH host key verification and fix self-hosted server support (#121)
* Add SSH host key verification with automatic trust and SCP-style URL support * Fix TypeScript errors for SSH host key schema and test mocks
This commit is contained in:
1 parent
677ce748cd
commit
7341dce1ef
25 files changed
+203
-123
No files matched your search
@@ -625,6 +625,10 @@ describe('GitService', () => {
|
||||
const mockRepo = {
|
||||
id: 1,
|
||||
fullPath: '/path/to/repo',
|
||||
localPath: '/path/to/repo',
|
||||
defaultBranch: 'main',
|
||||
cloneStatus: 'ready' as const,
|
||||
clonedAt: 123456,
|
||||
}
|
||||
getRepoByIdMock.mockReturnValue(mockRepo)
|
||||
executeCommandMock.mockResolvedValue('Everything up-to-date')
|
||||
@@ -643,6 +647,10 @@ describe('GitService', () => {
|
||||
const mockRepo = {
|
||||
id: 1,
|
||||
fullPath: '/path/to/repo',
|
||||
localPath: '/path/to/repo',
|
||||
defaultBranch: 'main',
|
||||
cloneStatus: 'ready' as const,
|
||||
clonedAt: 123456,
|
||||
}
|
||||
getRepoByIdMock.mockReturnValue(mockRepo)
|
||||
executeCommandMock.mockResolvedValueOnce('main\n').mockResolvedValueOnce('')
|
||||
@@ -659,7 +667,14 @@ describe('GitService', () => {
|
||||
|
||||
describe('fetch', () => {
|
||||
it('fetches from remote', async () => {
|
||||
const mockRepo = { id: 1, fullPath: '/path/to/repo' }
|
||||
const mockRepo = {
|
||||
id: 1,
|
||||
fullPath: '/path/to/repo',
|
||||
localPath: '/path/to/repo',
|
||||
defaultBranch: 'main',
|
||||
cloneStatus: 'ready' as const,
|
||||
clonedAt: 123456,
|
||||
}
|
||||
getRepoByIdMock.mockReturnValue(mockRepo)
|
||||
executeCommandMock.mockResolvedValue('')
|
||||
|
||||
@@ -671,7 +686,14 @@ describe('GitService', () => {
|
||||
|
||||
describe('pull', () => {
|
||||
it('pulls from remote', async () => {
|
||||
const mockRepo = { id: 1, fullPath: '/path/to/repo' }
|
||||
const mockRepo = {
|
||||
id: 1,
|
||||
fullPath: '/path/to/repo',
|
||||
localPath: '/path/to/repo',
|
||||
defaultBranch: 'main',
|
||||
cloneStatus: 'ready' as const,
|
||||
clonedAt: 123456,
|
||||
}
|
||||
getRepoByIdMock.mockReturnValue(mockRepo)
|
||||
executeCommandMock.mockResolvedValue('')
|
||||
|
||||
|
||||
Reference in new issue
Block a user