The following issue has been updated:

    Updater: dion gillard (mailto:[EMAIL PROTECTED])
       Date: Mon, 4 Aug 2003 10:55 AM
    Changes:
             description changed from When using the import tag from jelly to import a 
jelly script into maven, the import looks for the file in the bin directory of maven's 
home, instead of the plugin directory where the jelly script resides.
This only works this way when inside a goal. Outside a goal the file is found.

Example: Running the following goal as part of the webserver plugin

<?xml version="1.0"?>

<project xmlns:j="jelly:core" xmlns:log="jelly:log">
 
  <goal name="webserver:init">

    <j:import inherit="true" uri="./apache-2.x.jelly" />

    <condition property="maven.webserver.started">
      <http url="${maven.webserver.url}" />
    </condition>

    <available property="maven.webserver.installed"
      file="${maven.webserver.dir}" type="dir" />

    <j:set var="maven.webserver.installed.msg">
      <j:choose>
        <j:when test="${maven.webserver.installed}">installed</j:when>
        <j:otherwise>not installed</j:otherwise>
      </j:choose>
    </j:set>
    <j:set var="maven.webserver.started.msg">
      <j:choose>
        <j:when test="${maven.webserver.installed}">started</j:when>
        <j:otherwise>not started</j:otherwise>
      </j:choose>
    </j:set>
    <log:info trim="false">
Maven has determined your <j:expr value="${maven.webserver.fullname}"/> webserver 
instance is <j:expr value="${maven.webserver.installed.msg}"/> in directory [<j:expr 
value="${maven.webserver.dir}"/>] and <j:expr value="${maven.webserver.started.msg}"/> 
on <j:expr value="${maven.webserver.url}"/>
    </log:info>
  </goal>

</project>



would result in this output on the cli:



$ maven webserver:install
 __  __
|  \/  |__ Jakarta _ ___
| |\/| / _` \ V / -_) ' \  ~ intelligent projects ~
|_|  |_\__,_|\_/\___|_||_|   v. 1.0-beta-6

Blah Project (blah) 0.1alpha
G:\cygwin\home\plynch\dev\blah

webserver:init:

[ERROR] BUILD FAILED
[ERROR] File...... 
G:\cygwin\app\maven\home\plugins\maven-webserver-plugin-1.0\plugin.jelly
[ERROR] Element... j:import
[ERROR] Line...... 19
[ERROR] Column.... 57
[ERROR] G:\cygwin\app\maven\home\bin\.\apache-2.x.jelly (The system cannot find the 
file specified)
Total time:  12 seconds

-----------------

It should be finding the apache-2.x.jelly file in the webserver plugin directory, not 
in the bin dir of maven.

             Fix Version changed to 1.1
    ---------------------------------------------------------------------
For a full history of the issue, see:

  http://jira.codehaus.org/secure/ViewIssue.jspa?key=MAVEN-94&page=history

---------------------------------------------------------------------
View the issue:

  http://jira.codehaus.org/secure/ViewIssue.jspa?key=MAVEN-94


Here is an overview of the issue:
---------------------------------------------------------------------
        Key: MAVEN-94
    Summary: <j:import> inside maven goal looks for relative urls in wrong place
       Type: Bug

     Status: Unassigned
   Priority: Major

 Time Spent: Unknown
  Remaining: Unknown

    Project: maven
 Components: 
             jelly-integ
   Fix Fors:
             1.1
   Versions:
             1.0-beta-7

   Assignee: 
   Reporter: Peter Lynch

    Created: Thu, 22 Aug 2002 12:02 AM
    Updated: Mon, 4 Aug 2003 10:55 AM
Environment: Win 2K JDK 1.4

Description:
When using the import tag from jelly to import a jelly script into maven, the import 
looks for the file in the bin directory of maven's home, instead of the plugin 
directory where the jelly script resides.
This only works this way when inside a goal. Outside a goal the file is found.

Example: Running the following goal as part of the webserver plugin

<?xml version="1.0"?>

<project xmlns:j="jelly:core" xmlns:log="jelly:log">
 
  <goal name="webserver:init">

    <j:import inherit="true" uri="./apache-2.x.jelly" />

    <condition property="maven.webserver.started">
      <http url="${maven.webserver.url}" />
    </condition>

    <available property="maven.webserver.installed"
      file="${maven.webserver.dir}" type="dir" />

    <j:set var="maven.webserver.installed.msg">
      <j:choose>
        <j:when test="${maven.webserver.installed}">installed</j:when>
        <j:otherwise>not installed</j:otherwise>
      </j:choose>
    </j:set>
    <j:set var="maven.webserver.started.msg">
      <j:choose>
        <j:when test="${maven.webserver.installed}">started</j:when>
        <j:otherwise>not started</j:otherwise>
      </j:choose>
    </j:set>
    <log:info trim="false">
Maven has determined your <j:expr value="${maven.webserver.fullname}"/> webserver 
instance is <j:expr value="${maven.webserver.installed.msg}"/> in directory [<j:expr 
value="${maven.webserver.dir}"/>] and <j:expr value="${maven.webserver.started.msg}"/> 
on <j:expr value="${maven.webserver.url}"/>
    </log:info>
  </goal>

</project>



would result in this output on the cli:



$ maven webserver:install
 __  __
|  \/  |__ Jakarta _ ___
| |\/| / _` \ V / -_) ' \  ~ intelligent projects ~
|_|  |_\__,_|\_/\___|_||_|   v. 1.0-beta-6

Blah Project (blah) 0.1alpha
G:\cygwin\home\plynch\dev\blah

webserver:init:

[ERROR] BUILD FAILED
[ERROR] File...... 
G:\cygwin\app\maven\home\plugins\maven-webserver-plugin-1.0\plugin.jelly
[ERROR] Element... j:import
[ERROR] Line...... 19
[ERROR] Column.... 57
[ERROR] G:\cygwin\app\maven\home\bin\.\apache-2.x.jelly (The system cannot find the 
file specified)
Total time:  12 seconds

-----------------

It should be finding the apache-2.x.jelly file in the webserver plugin directory, not 
in the bin dir of maven.



---------------------------------------------------------------------
JIRA INFORMATION:
This message is automatically generated by JIRA.

If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa

If you want more information on JIRA, or have a bug to report see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to