TFS User`s Manual - TDN

advertisement
TFS User's Manual
(Team Foundation Server)
Revision 02
Page 1 of 81
TFS User's Manual
TOC
Page 2 of 81
TFS User's Manual
1.
INTRODUCTION
This document has the information on how to use Team Foundation Server (TFS) to control the file version
defined by PHOENIX phase 2 project.
2.
TFS CLIENT INSTALLATION (TEAM EXPLORER)
TFS (Team Foundation Server) is a central repository responsible for storing all files in the version control.
This way, in order to access the repository content, tools are necessary to query TFS. These are examples of
tools to be associated or not with IDE Visual Studio and Team Explorer Everywhere, a plug-in for IDE
Eclipse. The procedures to install Team Explorer 2010 are the following:
2.1
Copy directory ftp.totvs.com.br/tdi/VS2010TE to local directory and run setup.exe file (Link to Team
Explorer download: http://www.microsoft.com/downloads/en/details.aspx?FamilyID=fe4f9904-0480-4c9da264-02fedd78ab38).
2.2
Click Next.
Page 3 of 81
TFS User's Manual
2.3
Check the option I have read and accept the license terms and click Next.
Click Install.
Page 4 of 81
TFS User's Manual
2.3
3.
Click Finish.
CONNECTION TO TFS
TFS is grouped in Team Projects, a unit that centralizes, controls and stores all the artifacts produced by a
projects such as source codes. Team Projects are grouped in Team Projects Collections that aim to facilitate
the management of Team Projects with the same aspects. TOTVS adopted as a standard the use of a Team
Projects Collection for each DC (Development Center) and one for the Corporation IT area. It was also
adopted that each DC would create a Team Project for each product under the DC responsibility. Following,
the procedures to connect to a Team Project and access the product information.
Page 5 of 81
TFS User's Manual
3.1
Click Start > All Programs > Microsoft Visual Studio 2010 > Microsoft Visual Studio 2010.
3.2 First, configure TFS Proxy, click Tools > Options>Visual Studio Team Foundation Server. Enter:
tfscdjv.totvs.com.br:8081.
Page 6 of 81
TFS User's Manual
3.3
Click Team > Connect to Team Foundation Server.
Page 7 of 81
TFS User's Manual
3.4
Click Servers.
3.5
Click Add.
Page 8 of 81
TFS User's Manual
3.6
In Name or URL of Team Foundation Server, enter value tfscdjv.totvs.com.br and click OK.
3.7
Click Close.
Page 9 of 81
TFS User's Manual
3.8
4.
In Team Project Collections, select your Development Center (DC) or TI number if you are from TDI.
In Team Projects, select a product and click Connect.
WORKSPACE MAPPING
The Workspace maps folders in TFS version control of local folders in station. For this point on, you are able
to get files local copies and then change them locally, up to the point they are ready to be updated in the
version control through the operation Check In, also available from the Workspace.
You can synchronize your Workspace with the most recent changes in version control using Get Latest
Version, or even recover a specific version of any file through Get Specific Version.
If you want different file copies of version control in your computer, you can create more than a Workspace
for the same version control in TFS.
Following the procedures to manage a Workspace.
Page 10 of 81
TFS User's Manual
4.1
Expand one of your DC products and double-click Source Control.
4.2
Expand the selection box Workspace and select the option Workspaces.
Page 11 of 81
TFS User's Manual
4.3
Click Add.
4.4
In Name, enter the Training name (Private). In Working folders, click Source Control Folder and
select the DC root directory ($/). In Local Folder, create the folder C:\ControleVersão and click OK.
Page 12 of 81
TFS User's Manual
4.5
Click Close.
4.6
Expand the selection box Workspace, validate the creation of a private workspace and click
Workspace again.
Page 13 of 81
TFS User's Manual
4.7
In Name, enter the Training name (Public). In Permissions, select the option Public workspace and
click OK.
4.8
Click Close.
Page 14 of 81
TFS User's Manual
4.9
Expand the selection box Workspace, validate the creation of a public workspace and click
Workspaces again.
4.10 Select Training workspace (Public) and click Remove. Select the workspace with the station and click
Remove.
Page 15 of 81
TFS User's Manual
4.11 Select Training workspace (Private) and click Close.
5.
GET, CHANGE AND CHECK IN OF FILES
From the workspace, you are able to recover files from version control to a local station, change
them and check in sending changes to the version control.
Following the procedures for operations.
Page 16 of 81
TFS User's Manual
5.1
In Folders, select a DC product and a product folder with no sub folders, only files. Right-click folder
and click option Get Latest Version.
Page 17 of 81
TFS User's Manual
5.2
Select a file from the recovered folder, right-click option Check Out for Edit.
5.3
Click Check Out.
Page 18 of 81
TFS User's Manual
5.4
Double-click check out file, add, for instance, a comment //Changing in training, save file and close it.
5.5
Double-click another file not checked out, add, for instance, a comment //Second change in training,
save file and close it.
Page 19 of 81
TFS User's Manual
5.6
Note a file automatic check out after changing.
5.7
Right-click the last file changed and click Shelve Pending Changes.
Page 20 of 81
TFS User's Manual
5.8
In Shelveset name, enter the Training name, uncheck option Preserve pending changes locally and
click Shelve.
5.9
Select another file, right-click on it then click Lock.
Page 21 of 81
TFS User's Manual
5.10 Click Lock.
5.11 Select another file, right-click on it then click Delete.
Page 22 of 81
TFS User's Manual
5.12 Select another file, right-click on it then click Rename and change file name.
5.13 Select another file, right-click on it then click Move.
Page 23 of 81
TFS User's Manual
5.14 In To, select a directory to move file and click OK.
5.15 Right-click file changed and click Check In Pending Changes.
Page 24 of 81
TFS User's Manual
5.16 In Comment, enter Training comment, check all files changed and click Check In.
5.17 Check message and error informing the technical call code or Project\Requirement.
Page 25 of 81
TFS User's Manual
5.18 Right-click file changed and click Check In Pending Changes.
5.19 Click Check-in Notes.
Page 26 of 81
TFS User's Manual
5.20 In Technical Call, enter the technical call code and click Check In.
5.21 Check message and error informing the technical call does not have a development task under
execution.
Page 27 of 81
TFS User's Manual
5.22 Right-click file changed and click Check In Pending Changes.
5.23 Click Check-in Notes.
Page 28 of 81
TFS User's Manual
5.24 In Technical Call, enter the technical call number and click Check In.
6.
6.1
HISTORY QUERY, VERSION RECOVERY AND FILE COMPARISON
Right-click file changed and click View History.
Page 29 of 81
TFS User's Manual
6.2
Right-click the first row of version history and click Changeset Details.
6.3
Check the check in data and click Check-in Notes.
Page 30 of 81
TFS User's Manual
6.4
Check the check in notes data and click Cancel.
6.5
Right-click the second row of version history and click Compare.
Page 31 of 81
TFS User's Manual
6.6
Check the difference between versions and close the window.
6.7
Right-click the first row of version history and click Compare.
Page 32 of 81
TFS User's Manual
6.8
Check the last check in each file row; close it and also the version history.
6.9
Right-click file changed and click Check Out for Edit.
Page 33 of 81
TFS User's Manual
6.10 Right-click file and click Get Specific Version.
6.11 In Type, select Changeset option and click (...) changeset search button.
Page 34 of 81
TFS User's Manual
6.12 In Find options, click Find.
Page 35 of 81
TFS User's Manual
6.13 In Results, select the last row and click OK.
6.14 Click Merge Changes In Merge Tool.
Page 36 of 81
TFS User's Manual
6.15 Validate change and click OK.
6.16 Click Yes.
Page 37 of 81
TFS User's Manual
6.17 Right-click file changed and click Undo Pending Changes.
6.18 Click Undo Changes.
Page 38 of 81
TFS User's Manual
7.
MANAGEMENT OF BRANCHES
A Branch of files or folders are intelligent copies that do not replicate the whole source content, but only
the difference between the source content and changes made in Branch content. Branch list also enables
Merge of changes whether from origin to Branch, or Branch to origin in a simple way.
TOTVS Branches base strategy adopted is: Each DC product will have a Branch base (vBase), from which all
Branches come from. For each product innovation or maintenance version, a Branch from Branch base is
created according to the picture below.
Following the steps of Branches management procedure.
Page 39 of 81
TFS User's Manual
7.1
Right-click product branch vBase or Maxime folder, click Branching and Merging then click Branch.
7.2
In Target, after SourceCode, replace the existent value by /Innovation/Training-<your login> and
click OK.
Page 40 of 81
TFS User's Manual
7.3
Create a file in your desktop.
7.4
Right-click branch created and click Add Items to Folder.
Page 41 of 81
TFS User's Manual
7.5
Click Browse.
7.6
Select Desktop and click OK.
Page 42 of 81
TFS User's Manual
7.7
Select file created and click Next.
7.8
Click Finish.
Page 43 of 81
TFS User's Manual
7.9
Click File > Source Control > Unshelve Pending Changes.
7.10 Click Details.
Page 44 of 81
TFS User's Manual
7.11 Uncheck Preserver shelveset on Server option and click Unshelve.
7.12 In Branch, right-click file changed in prior steps adding, for instance, a comment //Changing in
training, and click Get Latest Version.
Page 45 of 81
TFS User's Manual
7.13 Double-click file and add, for instance, a comment //Changing made in Branch, save file and close it.
7.14 Click View > Other Windows > Pending Changes.
Page 46 of 81
TFS User's Manual
7.15 Click Check-in Notes.
7.16 In Technical Call, enter technical call code and click Check In.
Page 47 of 81
TFS User's Manual
7.17 Right-click file changed and select View History option.
7.18 Expand file branch record (last version history record with column Change and branch value) and
check file versions before Branch.
Page 48 of 81
TFS User's Manual
7.19 Select file first version and click Track Changeset.
7.20 Click Visualize.
Page 49 of 81
TFS User's Manual
7.21 Drag secondary branch (green) on main branch.
7.22 Click Next.
Page 50 of 81
TFS User's Manual
7.23 Click Next.
7.24 Click Finish.
Page 51 of 81
TFS User's Manual
7.25 Click View > Other Windows > Pending Changes.
7.26 Click Check-in Notes.
Page 52 of 81
TFS User's Manual
7.27 In Technical Call, enter technical call code and click Check In.
7.28 Close Pending Changes tab.
Page 53 of 81
TFS User's Manual
7.29 Click Rerun.
7.30 Click Visualize.
Page 54 of 81
TFS User's Manual
7.31 Validate changeset merge and click Timeline Tracking.
7.32 Validate changeset merge and close Tracking Changeset window.
Page 55 of 81
TFS User's Manual
7.33 Right-click branch created, select Branching and Merging option and click View Hierarchy.
7.34 Right-click branch and click Compare.
Page 56 of 81
TFS User's Manual
7.35 In Target Path click Browse and then Server Path.
7.36 Select main branch and click OK.
Page 57 of 81
TFS User's Manual
7.37 In Target Version, select Latest Version option in selection box Type and click OK.
7.38 Validate differences between branches and close Folder Difference tab.
Page 58 of 81
TFS User's Manual
7.39 Drag secondary branch on main branch.
7.40 Click Next.
Page 59 of 81
TFS User's Manual
7.41 Click Next.
7.42 Click Next.
Page 60 of 81
TFS User's Manual
7.43 Right-click branch created and click Delete.
7.44 Click View > Other Windows > Pending Changes.
Page 61 of 81
TFS User's Manual
7.45 Click Check-in Notes.
7.46 In Technical Call, enter technical call code and click Check In.
Page 62 of 81
TFS User's Manual
8.
MANAGEMENT OF LABELS
Labels enable you to take a “picture” of your files and recover them for query, compilation or even return
them to the same state when Label was created. Following the procedures for Labels management:
8.1
Right-click DC product version branch or Maxime folder for TDI and click Apply Label.
Page 63 of 81
TFS User's Manual
8.2
In Name, enter value Package – Training and click Create.
8.3
Right-click branch file and click View History.
Page 64 of 81
TFS User's Manual
8.4
Click Labels.
8.5
Validate Label creation, right-click on it, then click Edit Label.
Page 65 of 81
TFS User's Manual
8.6
Right-click label file, click Remove from Label, close Label tab and save label:
8.7
Click File > Source Control > Label > Find Label.
Page 66 of 81
TFS User's Manual
8.8
Click Find.
8.9
Select label created and click Delete then Close.
Page 67 of 81
TFS User's Manual
9.
MANAGEMENT OF PERMISSIONS
9.1
Right-click DC, select Team Project Collection Settings option and click Group Membership.
9.2
Click New.
Page 68 of 81
TFS User's Manual
9.3
In Group name, enter Training name. In Description, enter Group created for training description
and click OK.
9.4
Click Properties.
Page 69 of 81
TFS User's Manual
9.5
In Add member, select Windows User or Group option and click Add.
9.6
Enter DC user's login and click OK.
Page 70 of 81
TFS User's Manual
9.7
Click OK.
9.8
Click Close.
Page 71 of 81
TFS User's Manual
9.9
Right-click DC, select Team Project Collection Settings option and click Security.
9.10 In Add users and groups, select Team Foundation Server Group option and click Add.
Page 72 of 81
TFS User's Manual
9.11 Select group <DC>\Training previously created and click OK.
9.12 In Permissions for <DC>\Training, select View collection-level information permission, check Allow
option and click Close.
Page 73 of 81
TFS User's Manual
9.13 Select a DC product version folder, right-click on it and click Properties.
9.14 Click Security tab.
Page 74 of 81
TFS User's Manual
9.15 In Add users and groups, check Team Foundation Server Groups option and click Add.
9.16 Select group <DC>\Training previously created and click OK.
Page 75 of 81
TFS User's Manual
9.17 In Permissions for <DC>\Training, select Read permission, check Allow option and click OK.
9.18 Right-click DC, select Team Project Collection Settings option and click Group Membership.
Page 76 of 81
TFS User's Manual
9.19 Click Remove and then Close.
10. SOURCE SEARCH ENGINE IN TFS
This search engine enables you to search and/or query TFS to perform maintenance. This option facilitates
file localization within TFS in case you do not know the address.
For more options in TFS, please access FTP (ftp.totvs.com.br/TDI/TFS) and copy TFS Power Tools - Utilitário
de Pesquisa e Remoção de Check-in folder and install it in your local equipment:
Page 77 of 81
TFS User's Manual
After installation, the user selects the folder where TFS sources are and right-click on folder. In menu, item
“Find in Source Control” is displayed, select Wildcard option.
Page 78 of 81
TFS User's Manual
While selecting Wildcard option, a source search screen is displayed as follows.
Enter the program name you want to search and click Find.
Page 79 of 81
TFS User's Manual
A screen is displayed with the search results as follows.
Page 80 of 81
TFS User's Manual
11. TERMINOLOGY
Branch - A Branch of files or folders are intelligent copies that do not replicate the whole source content,
but only the difference between the source content and changes made in Branch content. Branch list also
enables Merge of changes whether from origin to Branch, or Branch to origin in a simple way.
Changeset – A changeset is a set of confirmed changes for one or more items stored in the TFS version
control repository. It also holds work item data, check-in notes and guidelines replacement information.
Check In – This functionality enables the user to release file and send changing file to server.
Check Out – This functionality enables the user to reserve a file.
Get – Check it in Workspace.
Label - It enables you to take a “picture” of your files and then recover them for query, compilation or even
return them to the same state when Label was created.
Shelving - It enables the user to store locally, in the equipment, (space created by TFS) the file which Check
In could not be done yet.
Team Projects - It controls and stores the artifacts produced by a project such as source codes. In each DC
was adopted a Team Project for each product under the DC responsibility.
Team Projects Collections – It facilitates the Team Projects management with the same aspects. TOTVS
adopted as a standard the use of a Team Projects Collection for each DC and one for the Corporation IT
area.
TFS - TFS (Team Foundation Server) is a central repository responsible for storing all files the version
control.
Workspace - It maps folders in TFS version control for local folders in station. For this point on, you are able
to get files local copies and then change them locally, up to the point they are ready to be updated in the
version control through the operation Check-in, also available from a Workspace. You can synchronize your
Workspace with the most recent changes in version control using Get Latest Version, or even recover a
specific version of any file through Get Specific Version.
If you want different file copies of version control in your computer, you can create more than a Workspace
for the same version control in TFS.
Following the procedures to manage a Workspace.
Page 81 of 81
Download