Skip to content

craft-hub / TeamGitSyncService

Class: TeamGitSyncService ​

Defined in: packages/craft-hub/src/team-git-sync.ts:48

Synchronize each Team's portable workspaces through its selected local Git checkout.

Constructors ​

Constructor ​

new TeamGitSyncService(dataDir, ownerScopes, workspaces): TeamGitSyncService

Defined in: packages/craft-hub/src/team-git-sync.ts:51

Parameters ​

dataDir ​

string

ownerScopes ​

OwnerScopeService

workspaces ​

WorkspaceService

Returns ​

TeamGitSyncService

Methods ​

configure() ​

configure(ownerScopeId, input): Promise<TeamGitSyncStatus>

Defined in: packages/craft-hub/src/team-git-sync.ts:60

Select a Team Git target without treating the repository as the Team identity.

Parameters ​

ownerScopeId ​

string

input ​
directory? ​

string

repositoryPath ​

string

Returns ​

Promise<TeamGitSyncStatus>


removeConfiguration() ​

removeConfiguration(ownerScopeId): Promise<TeamGitSyncConfigurationReceipt>

Defined in: packages/craft-hub/src/team-git-sync.ts:135

Detach a Team from its local checkout without deleting the shared snapshot.

Parameters ​

ownerScopeId ​

string

Returns ​

Promise<TeamGitSyncConfigurationReceipt>


restoreConfiguration() ​

restoreConfiguration(ownerScopeId, receipt): Promise<void>

Defined in: packages/craft-hub/src/team-git-sync.ts:148

Restore a detached Team configuration when lifecycle cleanup rolls back.

Parameters ​

ownerScopeId ​

string

receipt ​

TeamGitSyncConfigurationReceipt

Returns ​

Promise<void>


status() ​

status(ownerScopeId): Promise<TeamGitSyncStatus>

Defined in: packages/craft-hub/src/team-git-sync.ts:81

Inspect one Team's semantic divergence without running network Git operations.

Parameters ​

ownerScopeId ​

string

Returns ​

Promise<TeamGitSyncStatus>


synchronize() ​

synchronize(ownerScopeId, resolution?): Promise<TeamGitSyncStatus>

Defined in: packages/craft-hub/src/team-git-sync.ts:103

Synchronize one Team automatically or resolve an explicit divergence.

Parameters ​

ownerScopeId ​

string

resolution? ​

PersonalGitSyncResolution = 'auto'

Returns ​

Promise<TeamGitSyncStatus>

Released under the MIT License.