Skip to main content

workspaces_git_ahead_behind

Creates, updates, deletes, gets or lists a workspaces_git_ahead_behind resource.

Overview​

Nameworkspaces_git_ahead_behind
TypeResource
Idgoogle.dataform.workspaces_git_ahead_behind

Fields​

The following fields are returned by SELECT queries:

NameDatatypeDescription
commitsAheadinteger (int32)The number of commits in the remote branch that are not in the workspace.
commitsBehindinteger (int32)The number of commits in the workspace that are not in the remote branch.

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
fetch_git_ahead_behindselectprojectsId, locationsId, repositoriesId, workspacesIdremoteBranchFetches Git ahead/behind against a remote branch.

Parameters​

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
locationsIdstring
projectsIdstring
repositoriesIdstring
workspacesIdstring
remoteBranchstring

SELECT examples​

Fetches Git ahead/behind against a remote branch.

SELECT
commitsAhead,
commitsBehind
FROM google.dataform.workspaces_git_ahead_behind
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND repositoriesId = '{{ repositoriesId }}' -- required
AND workspacesId = '{{ workspacesId }}' -- required
AND remoteBranch = '{{ remoteBranch }}'
;