Version: 2020.3
LanguageEnglish
  • C#

Provider.IncomingChangeSetAssets

Suggest a change

Success!

Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.

Close

Submission failed

For some reason your suggested change could not be submitted. Please <a>try again</a> in a few minutes. And thank you for taking the time to help us improve the quality of Unity Documentation.

Close

Cancel

Declaration

public static VersionControl.Task IncomingChangeSetAssets(VersionControl.ChangeSet changeset);

Declaration

public static VersionControl.Task IncomingChangeSetAssets(string changesetID);

Parameters

changeset Incoming changeset.
changesetID Incoming changesetid.

Description

Given an incoming changeset this will start a task to query the version control server for which assets are part of the changeset.

using System.Collections.Generic;
using UnityEditor;
using UnityEditor.VersionControl;
using UnityEngine;

public class EditorScript : MonoBehaviour { [MenuItem("Version Control/ChangeSetAssets")] public static void ExampleChangeSetAssets() { Task t1 = Provider.IncomingChangeSetAssets("1111"); t1.Wait(); t1.assetList.ForEach(asset => Debug.Log(asset.name + " " + asset.state.ToString())); } }

The code above will return the names and version control states for the assets belonging to the "1111" incoming changeset.