Skip to end of metadata
Go to start of metadata


LAMS is released under the GPL license version 2.0, therefore any third party libraries we use must be compatible with the license.

License and Copyright Statement

All of our source code should have the following comment at the top. Note: when you are including multiple files into one file you don't need to include it in every subfile. e.g. when building a jsp using Tiles or a web.xml via webdoclet. We do not want our jsp files getting huge just due to the copyright statement.

Code Comment:

License Statement

CVS Id Keyword

In a similar manner, we aim to put the CVS $Id$ keyword at the top of our files. This expands to include the CVS version of the file and the user who submitted the file. This makes it easier to track changes to files that maybe done "outside" of the usual CVS process.

The keyword must appear at the top of all language properties files and sql scripts. These files may be sent as a batch of files to people to work on them and it makes it easier to manually check the changes when files are returned to the LAMS development team.

Code Templates

Set up your IDE to automatically insert the license and id entries in source files where possible.

In Eclipse, new Java files can be set up to include the text by going to Preferences -> Java -> Code Style -> Code Templates and pasting the following in the Code -> New Java files pattern.

Java Classes
Language Properties

Eclipse and CVS Keyword Expansion.

For CVS to expand out the $Id$ keyword, text/ASCII files should be set to be either "-kkv". If it doesn't have the "v", then the keyword won't expand. It is not usual to turn on the keyword expansion for binary files in case the $Id$ happens to occur for other reasons in the file.

In Eclipse text files default to "-kk". To change the mode of the files, click on a file or a folder and select "Team -> Change ASCII/Binary Property" from the popup menu. Change text files to "ASCII with keyword expansion (-kkv)". It is not possible to change binary files to support keyword expansion.

Only files that really are binary should be set to binary. For example, a swf file, a gif file or a jar file should be set to binary. A SQL file should be a text file. If a text file has accidently been put in as binary file then it should be possible to change the mode using "Team -> Change ASCII/Binary Property" option.

  • No labels