-
Book Overview & Buying
-
Table Of Contents
Spring Roo 1.1 Cookbook
If your project contain properties files, you may want to view their content. For instance, when we created the flight-app Roo project earlier, a log4j.properties file containing logging configuration was also created. In this recipe, we will look at the properties list command to view the contents of the log4j.properties file.
Start the Roo shell from C:\roo-cookbook\ch01-recipe directory, which contains the flight-app Roo project.
To view the contents of a properties file, the properties list command requires a path to the properties file and its name. The following properties list command displays the contents of the log4j.properties file:
roo> properties list --name log4j.properties --path SRC_MAIN_RESOURCES log4j.appender.R = org.apache.log4j.RollingFileAppender log4j.appender.R.File = application.log ... log4j.logger.sample.roo.flightapp = DEBUG log4j.rootLogger = DEBUG, stdout
The
Properties file add-on is responsible for processing the properties list command. The following table describes the arguments it accepts:
|
Argument |
Purpose |
|---|---|
|
|
It is a mandatory argument that identifies a path to the properties file. It only accepts pre-defined values like |
|
|
It is a mandatory argument that specifies the name of the properties file whose content you want to view. |
The next recipe, Managing properties defined in a properties file, shows how you can add, remove, and modify properties defined in properties files in your Roo project.
Change the font size
Change margin width
Change background colour