Shelve changes
You can save changes in your source control and share them with teammates without checking them into a branch. For example, to avoid errors while working on experimental code changes, you might not want to check these changes into a branch.
Shelve changes in the GUI
In the Pending Changes tab of the Unity DevOps Version Control, you can shelve any of your pending changes.
- Select Shelve. If you haven't added a comment, a dialogue displays to prompt you.
- Decide whether to keep the changes in your pending changes list or not:
- Undo changes to remove the changes from pending changes.
- Keep changes to keep the changes in pending changes.
To view any existing shelves, select the arrow icon on the Shelved button and select Show shelves.
Shelve changes in the CLI
Run the cm shelveset
command to commit a changeset that isn't associated with a branch:
>cm shelveset src\experimental_changes
Uploading file data
Confirming checkin operation
Modified src\experimental_changes
Created shelve sh:25@myrepo@localhost:8080 (mount:'/')
To apply the shelved changes to your workspace, run the apply
command:
>cm shelveset apply sh:25
The item /newtonraphson.cs#sh:25 has been added on source and will be added as result of the merge
Merging \src\experimental_changes\newtonraphson.cs
The revision \src\experimental_changes\newtonraphson.cs@sh:25 has been loaded