Issue Details (XML | Word | Printable)

Key: MAVEN-689
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Unassigned
Reporter: David Eric Pugh
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Maven 1

Using --dir and --find don't seem to work

Created: 18/Aug/03 06:16 PM   Updated: 08/Mar/06 10:47 PM   Resolved: 20/Aug/03 09:09 PM
Component/s: None
Affects Version/s: 1.0-beta-10
Fix Version/s: 1.0-rc1

Time Tracking:
Not Specified

Environment: win 2k and maven beta 10


 Description  « Hide

I am in c:\java and I want to run the maven build in c:\java\projectA\. It seems like maven --dir c:\java\projectA war:webapp would do it, but I get an error ons or it builds the Global Project:

C:\clients\Upstate>maven --dir c:\clients\upstate\fortius\ war
__ __

\/ __ Apache_ ___
  \/ / ` \ V / -) ' \ ~ intelligent projects ~
_   _,_ _/___ _ _ v. 1.0-beta-10

[echo] Assembling webapp Global Project
[echo] Building WAR Global Project
BUILD SUCCESSFUL
Total time: 2 seconds



dion gillard added a comment - 18/Aug/03 08:20 PM

Can you test this against the stable branch?

I believe this was fixed yesterday.


David Eric Pugh added a comment - 19/Aug/03 03:34 AM

Dion,

The --dir command works great with the new CVS HEAD (was STABLE).

However, the --find doesn't work, but that may be user error...! I have a project.xml in c:\clients\upstate\fortius, if I am in c:\clients\upstate I tried maven -f c:\clients\upstate\fortius test but it seemed to build locally in c:\clients\upstate, but use the project.xml in c:\clients\upstate\fortius.

This could be because I don't understand the semantics of --find. However, --dir is what I really wanted, so I'm happy.


dion gillard added a comment - 20/Aug/03 01:21 AM

--find doesn't take an argument.

It simply starts from ${user.dir} and goes looking up the tree till it finds a project.xml

I've added a fix to App.java, so that whereever it does find it becomes the CWD.

Can you retest?


dion gillard added a comment - 20/Aug/03 09:09 PM

C:\source\maven>cd src\java

C:\source\maven\src\java>maven --find test
__ __

\/ __ Apache_ ___
  \/ / ` \ V / -) ' \ ~ intelligent projects ~
_   _,_ _/___ _ _ v. 1.0-rc1-SNAPSHOT

java:prepare-filesystem:

java:compile:
[echo] Compiling to C:\source\maven/target/classes

java:jar-resources:

test:prepare-filesystem:

test:test-resources:

test:compile:

test:test:
...
...
...

jar:jar:
[jar] Building jar: C:\source\maven\target\maven.jar
BUILD SUCCESSFUL
Total time: 55 seconds
Finished at: Thu Aug 21 12:00:07 EST 2003

C:\source\maven\src\java>