Chapter 6. How to Move a Project

Table of Contents

1. Relocating a Project
1.1. From within Aegis
1.2. From outside Aegis
2. Renaming a Project
2.1. From within Aegis
2.2. From outside Aegis
2.3. Project Aliases

By "move a project", you may wish to change the project's name but leave the project files in the same location, or you may wish to change a projects directory location and leave it with the same name. This section covers both.

There are two ways to move a project. One is from within Aegis, and one is from outside Aegis. Each section below covers both methods.

1. Relocating a Project

This section deals with moving a project's files from one file system location to another.

1.1. From within Aegis

This works best when you are moving a project from one machine to another. It is a very good idea if there are no active changes on any branch.

Step 1: You need to know where in the file system the project currently resides. Take a look in the projects list (ael p) and see the directory reported for the trunk of the project. Ignore any active branches.

Step 2: Usually, when you remove a project, Aegis deleted all of the project files. However the aerm -keep option tells Aegis to remove the project name, but keep all of the project files.

Step 3: Move the files to their new location, you need all of the files below the directory tree you found in step 1. This may be a simple file move, or may involve copying the files to tape, and then unpacking on a new machine. Remember to make sure the file ownerships are set the way you want (usually, this means "preserved exactly").

Step 4: Tell Aegis where the project is. To do this, use the -dir and -keep options of the aenpr(1) command.

1.2. From outside Aegis

This works best of the project is staying on the same machine, or the same NFS network.

Step 1: You need to know where in the file system the project currently resides. Take a look in the projects list (ael p) and see the directory reported for the trunk of the project. Ignore any active branches.

Step 2: Move the files to the new location.

Step 3: Edit the /var/lib/aegis/state file and edit the path appropriately to tell Aegis where you moved the files to. You will need to be root for this step.

2. Renaming a Project

This section deals with changing a project's name without moving is files.

2.1. From within Aegis

Step 1: You need to know where in the file system the project currently resides. Take a look in the projects list (ael p) and see the directory reported for the trunk of the project. Ignore any active branches.

Step 2: Usually, when you remove a project, Aegis deleted all of the project files. However the aerm -keep option tells Aegis to remove the project name, but keep all of the project files.

Step 3: Tell Aegis where the project is, using the new name. To do this, use the -dir and -keep options of the aenpr(1) command.

2.2. From outside Aegis

Step 1: Edit the /var/lib/aegis/state file and edit the name appropriately to tell Aegis the new name of the project. You will need to be root for this step.

2.3. Project Aliases

You may need some transition time for your developers. Either before or after you rename the project, you may want to consider adding a project alias (see aenpa(1) for more information) so that the project has "both" names for a while.