- In this lesson you will learn the following concepts
- Checking a project into the SCM
- Add project to SCM
- Opening a project from the SCM
- Configuring the SCM
Lesson 12.2. Checking a project into the SCM
In this lesson you will learn the following concepts
- Adding a project to the SCM.
- Opening a project from the SCM.
- Configuring the SCM.
Estimated time: 15 mn
Checking a project into the SCM
Add project to SCM
To use an existing project with the Source Code Manager, simply add it to the repository.
- We will add the "Full_WEBDEV_Site" project to the repository.
- Open the project you worked on in the previous lesson.
- Go to the WEBDEV home page (Ctrl + <).
- On the home page, click "Tutorial", then in "Parts 11 and 12", double-click "Full WEBDEV Site (Exercise)".
- A dialogue box prompts you to open the project you worked on in the previous lesson. You can open the local copy or the original project. Select "Open the local copy".
|A corrected project is available. This project allows you to perform the different operations in this lesson. To open the corrected project, go to the home page and click "Tutorial", then in "Parts 11 and 12", double-click "Full WEBDEV Site (Answers)".|
|Sharing project elements|
When the projects that share the same resources (analysis, windows, etc.) are integrated into the SCM, the relevant elements can be shared between the different projects. Therefore, the same element is checked in only once and the modifications are automatically applied to the other projects.
Opening a project from the SCM
In our example, the project is checked into the SCM and can be used directly.
In a real case, in order for other developers to work on a project located in the Source Code Manager, they must get a copy of this project locally.
To do so, follow these steps:
- Open the project from the Source Code Manager: on the "Home" tab, in the "General" group, expand "Open" and select "Open a project from the SCM".
- In the "HFSQL C/S" tab, enter the repository location parameters and validate (this step is necessary only if the current project is not included in the SCM):
- In the window that appears, indicate the connection and local directory if necessary:
Remark: If the project was already opened from the SCM, the SCM proposes to open the project as usual or to overwrite the content (to retrieve the entire project).
This operation must be performed only once by each developer who uses the project.
The developer who added the project to the Source Code Manager (you in this case) has no operations to perform.
|Next time, you will be able to open a project included in the SCM as any other project: simply open the project (".WWP" file) corresponding to the local copy.|
Configuring the SCM
Before you start working on the elements of the project included in the SCM, you must configure the mode for checking out the project elements.
When working on the elements of a project in the SCM, the element must be checked out from the repository before it can be modified, then it must be checked back in once the changes have been made. Therefore, the modified element becomes available to all SCM users.
WEBDEV features two modes to check out the project elements:
- standard mode: if you open an element that has not been checked out from the SCM, a panel indicates that the element must be checked out to modify it. The element can be checked out immediately (check-out button found in the dialog box).
- automatic mode: if you try to modify an element that has not yet been checked out, the SCM automatically prompts you to check it out. Once the check-out is validated, the element can be modified.
Remark: this mode is not recommended when using the SCM with a slow Internet connection.
The automatic check-out will be used in this tutorial.
- To make sure that the automatic check-out is enabled, on the "Home" tab, in the "Environment" group, expand "Options" and select "General options of WEBDEV". In the "General" tab, check (if necessary) "Check out elements on first modification".