Showing the changes to apps/server/src/sourceControl/SourceControlProvider.ts (1 of 42 files). Show all
Unified · Split
| @@ -49,54 +49,52 @@ export function sourceControlRefFromInput(input: { · 48 unmodified lines | ||
| 49 | 49 | return input.source ?? parseSourceControlOwnerRef(input.headSelector); |
| 50 | 50 | } |
| 51 | 51 | |
| 52 | −export interface SourceControlProviderShape { | |
| 53 | − readonly kind: SourceControlProviderKind; | |
| 54 | − readonly listChangeRequests: (input: { | |
| 55 | − readonly cwd: string; | |
| 56 | − readonly context?: SourceControlProviderContext; | |
| 57 | − readonly source?: SourceControlRefSelector; | |
| 58 | − readonly headSelector: string; | |
| 59 | − readonly state: ChangeRequestState | "all"; | |
| 60 | − readonly limit?: number; | |
| 61 | − }) => Effect.Effect<ReadonlyArray<ChangeRequest>, SourceControlProviderError>; | |
| 62 | − readonly getChangeRequest: (input: { | |
| 63 | − readonly cwd: string; | |
| 64 | − readonly context?: SourceControlProviderContext; | |
| 65 | − readonly reference: string; | |
| 66 | − }) => Effect.Effect<ChangeRequest, SourceControlProviderError>; | |
| 67 | − readonly createChangeRequest: (input: { | |
| 68 | − readonly cwd: string; | |
| 69 | − readonly context?: SourceControlProviderContext; | |
| 70 | − readonly source?: SourceControlRefSelector; | |
| 71 | − readonly target?: SourceControlRefSelector; | |
| 72 | − readonly baseRefName: string; | |
| 73 | − readonly headSelector: string; | |
| 74 | − readonly title: string; | |
| 75 | − readonly bodyFile: string; | |
| 76 | − }) => Effect.Effect<void, SourceControlProviderError>; | |
| 77 | − readonly getRepositoryCloneUrls: (input: { | |
| 78 | − readonly cwd: string; | |
| 79 | − readonly context?: SourceControlProviderContext; | |
| 80 | − readonly repository: string; | |
| 81 | − }) => Effect.Effect<SourceControlRepositoryCloneUrls, SourceControlProviderError>; | |
| 82 | − readonly createRepository: (input: { | |
| 83 | − readonly cwd: string; | |
| 84 | − readonly repository: string; | |
| 85 | − readonly visibility: SourceControlRepositoryVisibility; | |
| 86 | − }) => Effect.Effect<SourceControlRepositoryCloneUrls, SourceControlProviderError>; | |
| 87 | − readonly getDefaultBranch: (input: { | |
| 88 | − readonly cwd: string; | |
| 89 | − readonly context?: SourceControlProviderContext; | |
| 90 | − }) => Effect.Effect<string | null, SourceControlProviderError>; | |
| 91 | − readonly checkoutChangeRequest: (input: { | |
| 92 | − readonly cwd: string; | |
| 93 | − readonly context?: SourceControlProviderContext; | |
| 94 | − readonly reference: string; | |
| 95 | − readonly force?: boolean; | |
| 96 | − }) => Effect.Effect<void, SourceControlProviderError>; | |
| 97 | −} | |
| 98 | − | |
| 99 | 52 | export class SourceControlProvider extends Context.Service< |
| 100 | 53 | SourceControlProvider, |
| 101 | − SourceControlProviderShape | |
| 54 | + { | |
| 55 | + readonly kind: SourceControlProviderKind; | |
| 56 | + readonly listChangeRequests: (input: { | |
| 57 | + readonly cwd: string; | |
| 58 | + readonly context?: SourceControlProviderContext; | |
| 59 | + readonly source?: SourceControlRefSelector; | |
| 60 | + readonly headSelector: string; | |
| 61 | + readonly state: ChangeRequestState | "all"; | |
| 62 | + readonly limit?: number; | |
| 63 | + }) => Effect.Effect<ReadonlyArray<ChangeRequest>, SourceControlProviderError>; | |
| 64 | + readonly getChangeRequest: (input: { | |
| 65 | + readonly cwd: string; | |
| 66 | + readonly context?: SourceControlProviderContext; | |
| 67 | + readonly reference: string; | |
| 68 | + }) => Effect.Effect<ChangeRequest, SourceControlProviderError>; | |
| 69 | + readonly createChangeRequest: (input: { | |
| 70 | + readonly cwd: string; | |
| 71 | + readonly context?: SourceControlProviderContext; | |
| 72 | + readonly source?: SourceControlRefSelector; | |
| 73 | + readonly target?: SourceControlRefSelector; | |
| 74 | + readonly baseRefName: string; | |
| 75 | + readonly headSelector: string; | |
| 76 | + readonly title: string; | |
| 77 | + readonly bodyFile: string; | |
| 78 | + }) => Effect.Effect<void, SourceControlProviderError>; | |
| 79 | + readonly getRepositoryCloneUrls: (input: { | |
| 80 | + readonly cwd: string; | |
| 81 | + readonly context?: SourceControlProviderContext; | |
| 82 | + readonly repository: string; | |
| 83 | + }) => Effect.Effect<SourceControlRepositoryCloneUrls, SourceControlProviderError>; | |
| 84 | + readonly createRepository: (input: { | |
| 85 | + readonly cwd: string; | |
| 86 | + readonly repository: string; | |
| 87 | + readonly visibility: SourceControlRepositoryVisibility; | |
| 88 | + }) => Effect.Effect<SourceControlRepositoryCloneUrls, SourceControlProviderError>; | |
| 89 | + readonly getDefaultBranch: (input: { | |
| 90 | + readonly cwd: string; | |
| 91 | + readonly context?: SourceControlProviderContext; | |
| 92 | + }) => Effect.Effect<string | null, SourceControlProviderError>; | |
| 93 | + readonly checkoutChangeRequest: (input: { | |
| 94 | + readonly cwd: string; | |
| 95 | + readonly context?: SourceControlProviderContext; | |
| 96 | + readonly reference: string; | |
| 97 | + readonly force?: boolean; | |
| 98 | + }) => Effect.Effect<void, SourceControlProviderError>; | |
| 99 | + } | |
| 102 | 100 | >()("t3/sourceControl/SourceControlProvider") {} |