continuum-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From eveni...@apache.org
Subject svn commit: r306606 - in /maven/continuum/trunk: continuum-api/src/main/java/org/apache/maven/continuum/configuration/ continuum-core/src/main/java/org/apache/maven/continuum/ continuum-core/src/main/java/org/apache/maven/continuum/configuration/ conti...
Date Thu, 06 Oct 2005 12:10:53 GMT
Author: evenisse
Date: Thu Oct  6 05:10:44 2005
New Revision: 306606

URL: http://svn.apache.org/viewcvs?rev=306606&view=rev
Log:
o applicationHome is now accessible for configuration screens
o Check if working directory, build output directory and base url aren't null

Modified:
    maven/continuum/trunk/continuum-api/src/main/java/org/apache/maven/continuum/configuration/ConfigurationService.java
    maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/DefaultContinuum.java
    maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/configuration/DefaultConfigurationService.java
    maven/continuum/trunk/continuum-web/src/main/resources/templates/screens/Configure.vm
    maven/continuum/trunk/continuum-web/src/main/resources/templates/screens/EditContinuumConfiguration.vm

Modified: maven/continuum/trunk/continuum-api/src/main/java/org/apache/maven/continuum/configuration/ConfigurationService.java
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-api/src/main/java/org/apache/maven/continuum/configuration/ConfigurationService.java?rev=306606&r1=306605&r2=306606&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-api/src/main/java/org/apache/maven/continuum/configuration/ConfigurationService.java
(original)
+++ maven/continuum/trunk/continuum-api/src/main/java/org/apache/maven/continuum/configuration/ConfigurationService.java
Thu Oct  6 05:10:44 2005
@@ -31,6 +31,8 @@
     //
     // ----------------------------------------------------------------------
 
+    File getApplicationHome();
+
     boolean isInitialized();
 
     void setInitialized( boolean initialized );

Modified: maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/DefaultContinuum.java
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/DefaultContinuum.java?rev=306606&r1=306605&r2=306606&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/DefaultContinuum.java
(original)
+++ maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/DefaultContinuum.java
Thu Oct  6 05:10:44 2005
@@ -1061,11 +1061,32 @@
                 configurationService.setGuestAccountEnabled( false );
             }
 
-            configurationService.setWorkingDirectory( configurationService.getFile( (String)
configuration.get( "conf.workingDirectory" ) ) );
+            if ( configuration.get( "conf.workingDirectory" ) == null )
+            {
+                configurationService.setWorkingDirectory( configurationService.getFile( (String)
configuration.get( "conf.workingDirectory" ) ) );
+            }
+            else
+            {
+                throw new ContinuumException( "working directory can't be null" );
+            }
 
-            configurationService.setBuildOutputDirectory( configurationService.getFile( (String)
configuration.get( "conf.buildOutputDirectory" ) ) );
+            if ( configuration.get( "conf.buildOutputDirectory" ) == null )
+            {
+                configurationService.setBuildOutputDirectory( configurationService.getFile(
(String) configuration.get( "conf.buildOutputDirectory" ) ) );
+            }
+            else
+            {
+                throw new ContinuumException( "build output directory can't be null" );
+            }
 
-            configurationService.setUrl( (String) configuration.get( "conf.url" ) );
+            if ( configuration.get( "conf.url" ) == null )
+            {
+                configurationService.setUrl( (String) configuration.get( "conf.url" ) );
+            }
+            else
+            {
+                throw new ContinuumException( "base url can't be null" );
+            }
 
             configurationService.setCompanyName( (String) configuration.get( "conf.companyName"
) );
 

Modified: maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/configuration/DefaultConfigurationService.java
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/configuration/DefaultConfigurationService.java?rev=306606&r1=306605&r2=306606&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/configuration/DefaultConfigurationService.java
(original)
+++ maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/configuration/DefaultConfigurationService.java
Thu Oct  6 05:10:44 2005
@@ -67,6 +67,11 @@
     //
     // ----------------------------------------------------------------------
 
+    public File getApplicationHome()
+    {
+        return applicationHome;
+    }
+
     public void setInitialized( boolean initialized )
     {
         systemConf.setInitialized( initialized );

Modified: maven/continuum/trunk/continuum-web/src/main/resources/templates/screens/Configure.vm
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-web/src/main/resources/templates/screens/Configure.vm?rev=306606&r1=306605&r2=306606&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-web/src/main/resources/templates/screens/Configure.vm
(original)
+++ maven/continuum/trunk/continuum-web/src/main/resources/templates/screens/Configure.vm
Thu Oct  6 05:10:44 2005
@@ -35,11 +35,11 @@
       <table cellspacing="2" cellpadding="3" width="700">
         <tr>
           <td>Working Directory :</td>
-          <td><input type="text" name="workingDirectory" value="working-directory"
size="50"> If you define a relative path, it will be relative to $CONTINUUM_HOME/apps/continuum/</td>
+          <td><input type="text" name="workingDirectory" value="working-directory"
size="50"> If you define a relative path, it will be relative to $continuum.configuration.applicationHome</td>
         </tr>
         <tr>
           <td>Build Output Directory :</td>
-          <td><input type="text" name="buildOutputDirectory" value="build-output-directory"
size="50"> If you define a relative path, it will be relative to $CONTINUUM_HOME/apps/continuum/</td>
+          <td><input type="text" name="buildOutputDirectory" value="build-output-directory"
size="50"> If you define a relative path, it will be relative to $continuum.configuration.applicationHome</td>
         </tr>
       </table>
 

Modified: maven/continuum/trunk/continuum-web/src/main/resources/templates/screens/EditContinuumConfiguration.vm
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-web/src/main/resources/templates/screens/EditContinuumConfiguration.vm?rev=306606&r1=306605&r2=306606&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-web/src/main/resources/templates/screens/EditContinuumConfiguration.vm
(original)
+++ maven/continuum/trunk/continuum-web/src/main/resources/templates/screens/EditContinuumConfiguration.vm
Thu Oct  6 05:10:44 2005
@@ -19,11 +19,11 @@
         </tr>
         <tr class="b">
           <th>Working Directory</th>
-          <td><input type="text" name="conf.workingDirectory" value="$continuum.configuration.workingDirectory"
size="100"/></td>
+          <td><input type="text" name="conf.workingDirectory" value="$continuum.configuration.workingDirectory"
size="100"/> If you define a relative path, it will be relative to $continuum.configuration.applicationHome</td>
         </tr>
         <tr class="b">
           <th>Build Output Directory</th>
-          <td><input type="text" name="conf.buildOutputDirectory" value="$continuum.configuration.buildOutputDirectory"
size="100"/></td>
+          <td><input type="text" name="conf.buildOutputDirectory" value="$continuum.configuration.buildOutputDirectory"
size="100"/> If you define a relative path, it will be relative to $continuum.configuration.applicationHome</td>
         </tr>
         <tr class="b">
           <th>Base URL</th>



Mime
View raw message