BuildForge Help

Adding Baselines and Checkpoints with the .scan Command

You can use the .scan command to add more information to the BOM. When the .scan command is executed, the system stores information about the state of the files in the step's working directory.

The command has two forms.
.scan baseline
Stores a list of all files in the step's working directory tree, with MD5 values for each. The system displays the list in the BOM for the job. You may want to issue this command after performing some setup steps and checking out an appropriate set of files. You can have multiple baseline commands in a project, but each one resets the list to the state of the step's working directory when the .baseline command executes.
.scan checkpoint
Stores a list of all new, changed, and deleted files since last .scan baseline or .scan checkpoint in the project, with MD5 values for each file. As with the .scan baseline command, the system displays the list in the BOM. You must issue a .scan baseline command before the first .scan checkpoint command in your project. A .scan checkpoint command that precedes a .scan baseline command will be ignored.

The following example shows how .scan baseline and checkpoint commands work together:

Number

Step

Files after step

BOM data

1

Check out initial files

config.c

execute.c

 

2

Baseline

config.c

execute.c

Baseline:

config.c

execute.c

3

Add data file

config.c

execute.c

data.txt

 

4

Checkpoint 1

config.c

execute.c

data.txt

Checkpoint 1:

Added data.txt

5

Add more data files

config.c

execute.c

data.txt

data2.txt

data3.txt

 

6

Delete data.txt

config.c

execute.c

data2.txt

data3.txt

 

7

Checkpoint 2

config.c

execute.c

data.txt

data2.txt

data3.txt

Checkpoint 2:

Added data2.txt, data3.txt

Deleted data.txt