Plastic SCM User’s Guide

 

Table of Contents

1.    Introduction. 1

1.1.    What is Plastic SCM? 1

1.2.    Problems without version control 1

1.3.    Components 2

2.    Basic concepts. 4

2.1.    Repository. 4

2.2.    Item. 5

2.3.    Revisions 5

2.4.    Branch. 6

2.4.1.    Version tree. 9

2.4.2.    Branch explorer 11

2.5.    Smart branches 12

2.6.    Workspace. 13

2.7.    Label (marker) 14

3.    Plastic SCM operations. 16

3.1.    Creating a repository. 17

3.2.    Creating workspaces 17

3.3.    Add. 18

3.4.    Check in. 23

3.5.    Update. 24

3.5.1.    Modified items in the workspace. 24

3.5.2.    Items marked as .unloaded. 25

3.5.3.    Checkout shelving. 25

3.5.4.    Parallel update. 26

3.6.    Check out 26

3.6.1.    Internal Checkout details 28

3.7.    Displaying pending checkins 28

3.8.    Undo checkout 29

3.9.    Revert to a previous revision. 30

3.10.  Creating a branch. 32

3.11.  Editing branch properties 33

3.12.  Merge (integration) 36

3.12.1.  Merge conflict types 36

3.12.2.  Contributors 37

3.12.3.  Merges from the same branch. 38

3.12.4.  Merging from different branches 39

3.12.5.  Merging from a branch and a label 40

3.12.6.  Merge from a label 41

3.12.7.  Merging from a changeset 41

3.12.8.  Merging from a revision. 42

3.12.9.  Merging from the command line. 42

3.12.10.      Cherry Picking or selective merge. 43

3.12.11.      Cherry Picking from branch. 45

3.12.12.      Merging an interval of changes 45

3.13.  Subtractive merge (desintegration) 46

3.13.1.  Subtracting a revision interval 50

3.13.2.  Subtracting a changeset 52

3.14.  Creating a label 52

3.15.  Applying a label 53

3.16.  Working with attributes 53

3.16.1.  Creating an attribute. 54

3.16.2.  Applying an attribute. 54

3.16.3.  Editing an attribute value. 55

3.16.4.  Deleting an attribute application. 56

3.16.5.  Querying objects with attributes 56

4.    Starting up a project 58

4.1.    Creating a repository. 58

4.2.    Creating workspaces 59

4.3.    Performing a first code import 60

4.4.    Starting to work 62

4.4.1.    Update. 62

4.5.    Checking out items to work with them. 63

4.6.    Finding checked out files 64

5.    Workspace selectors in depth. 65

5.1.    Selector´s appearance. 65

5.2.    Selector definition. 66

5.3.    Path rules 68

5.4.    The norecursive path rule option. 68

5.5.    Specifying wildcards on the path selection rule. 69

5.6.    Retrieving an item’s specific revision. 70

5.7.    Smart branch rules 70

6.    Object specifications. 72

6.1.    Revision specifications 72

6.2.    Branch specifications 73

6.3.    Item specifications 73

6.4.    Label specifications 73

6.5.    Repository specifications 73

6.6.    Workspace specifications 74

6.7.    Repository server specifications 74

6.8.    Workspace server specifications 74

7.    Plastic SCM GUI Tool 75

7.1.    The main window. 75

7.2.    The view system. 76

7.3.    Workspace selection. 77

7.4.    Modifying the workspace selector 77

7.5.    Context menus 78

7.6.    The differences dialog. 83

7.7.    The differences tool 84

7.8.    The image diff tool 85

7.9.    The merge dialog. 86

7.10.  The merge tool for text files 88

7.11.  The binary merge tool 89

8.    Managing projects with Plastic SCM.. 91

8.1.    Working on the main branch. 91

8.2.    Branch per developer 92

8.3.    Branch per task 93

9.    Visual Studio Plug In. 95

9.1.    Adding projects to the source control system. 95

9.2.    Opening existing projects under source control 96

9.3.    Operations 97

9.4.    Additional source control operations 98

9.5.    Working disconnected. 99

10. Jdeveloper plugin. 101

10.1.  Adding projects to the source control system. 101

10.2.  Operations 103

10.3.  Decorators 105

11. Eclipse Plug In. 106

11.1.  Adding projects to the source control system. 106

11.2.  Opening existing projects under source control 109

11.3.  Operations 109

11.4.  Refactor support 111

11.5.  Preferences 112

11.6.  Decorators 112

11.7.  The Plastic SCM perspective. 113

11.7.1.  Console view. 114

11.7.2.  Workspace explorer view. 114

11.7.3.  Pending checkouts view. 116

12. IntelliJ 5 Plug in. 117

12.1.  Setup the Plug in. 117

12.2.  Checkout from Version Control 119

12.3.  Item status overview. 123

12.4.  Opening existing projects under source control 123

12.5.  Basic operations 123

12.6.  Refactor support 128

13. IntelliJ 8 Plug in. 130

13.1.  Setup the Plug in. 130

13.2.  Checkout from Version Control 132

13.3.  Item status overview. 134

13.4.  Opening existing projects under source control 134

13.5.  Basic operations 135

13.6.  Refactor support 141

13.7.  Work offline mode. 141

14. Simple Query System.. 142

14.1.  Query Language. 142

14.2.  Usage examples 146

14.3.  Query language grammar 148

15. Advanced Query System (AQS). 149

15.1.  Query Language. 149

15.2.  Usage examples 153

16. Import from other SCM.. 155

16.1.  Introduction. 155

16.2.  Operating Mode. 155

16.2.1.  Previous steps 155

16.2.2.  Execution. 155

16.2.3.  Users 156

16.2.4.  Import mechanism. 156

16.3.  Importer providers 157

16.3.1.  Microsoft Visual SourceSafe. 157

16.3.2.  CVS. 158

16.3.3.  Subversion. 159

17. References. 161


Figures

Figure 1: Plastic SCM components and structure. 2

Figure 2: Types of objects a repository can hold. 4

Figure 3: Sample items and private items 5

Figure 4: Relation between revisions and items 6

Figure 5: Sample item history. 6

Figure 6: Representation of the item history. 6

Figure 7: Item revisions contained in a branch. 7

Figure 8: Branch representation. 7

Figure 9: Branch inheritance representation. 8

Figure 10: How the workspace maps branch’s revisions 9

Figure 11: version tree in the repository structure. 10

Figure 12: hello.cpp item calculated by Plastic SCM. 10

Figure 13: Sample version tree. 11

Figure 14: Sample Branch Explorer 12

Figure 15. Smart branches define dynamic branch hierarchies 13

Figure 16: How revisions map to a workspace. 14

Figure 17: Each developer can have many workspaces 14

Figure 18: Labels applied to revisions 15

Figure 19: base version control operations 16

Figure 20: Repository creation dialog. 17

Figure 21: Creating a new workspace. 18

Figure 22: Items added from visual studio. 20

Figure 23: Add to source control from Visual Studio. 21

Figure 24: Elements protected under Visual Studio. 21

Figure 25: Eclipse share project option. 22

Figure 26: Add to source control from Eclipse. 22

Figure 27: Eclipse check in recursively functionality. 23

Figure 28: Checked out elements before update. 25

Figure 29: Check out protection. 25

Figure 30: Check out view. 26

Figure 31: Check out recovery. 26

Figure 32: Checked-out tick detail in Visual Studio. 27

Figure 33: checkout dialog in Visual Studio. 27

Figure 34: A revision is created in the checkout operation. 28

Figure 35: Pending checkouts view in the GUI tool 28

Figure 36: View pending checkins in Visual Studio. 29

Figure 37: Undo checkout from the GUI tool 30

Figure 38. Revert operation. 31

Figure 39. Revert from GUI 31

Figure 40: Creating a child branch in the GUI tool 32

Figure 41. Smart branch creation dialog. 33

Figure 42. Editing smart branch properties 34

Figure 43. How smart branches evolve through time. 35

Figure 44. Two smart branches hierarchy samples 35

Figure 45: List of items to be merged. 36

Figure 46: Revisions included on a merge operation. 37

Figure 47: Merge from the same branch. 38

Figure 48: Basic merge, merge completed. 39

Figure 49: parallel development scenario. 39

Figure 50: Developers work on the item. 40

Figure 51: Both branches have been integrated. 40

Figure 52: Labeled revisions on the branch have been merged. 41

Figure 53: Regular Merge. 44

Figure 54: Cherry pick 44

Figure 55: Cherry pick from branch. 45

Figure 56. Subtractive merge, initial code. 46

Figure 57. Subtractive merge, first modification. 47

Figure 58. Subtractive merge, second modification. 47

Figure 59. Subtractive merge, version tree after merging the first change. 48

Figure 60. Subtractive merge, file after the two changes 48

Figure 61. Substractive revision merge from the GUI 49

Figure 62. Subtractive merge showing the result of the file. 49

Figure 63. How subtractive merge works 50

Figure 64. Version tree after a subtractive merge showing the subtractive link 50

Figure 65. Subtractive merge of an interval 51

Figure 66. Subtractive merge from GUI 51

Figure 67: Creating a new label 52

Figure 68: Apply label to workspace content 53

Figure 69: Create new attribute. 54

Figure 70: How to apply an attribute. 55

Figure 71: Apply attribute dialog. 55

Figure 72: Edit the attribute value. 56

Figure 73: Delete the attribute application. 56

Figure 74: Query objects with attributes 57

Figure 75: New Repository. 59

Figure 76: Creating a workspace. 59

Figure 77: Add solution to source control 60