Commit Graph

2776 Commits

Author SHA1 Message Date
John Dennis Casey 9a3085813d Working on MNG-483
o Added @requiresDirectInvocation (was: @cliOnly, but this implies m2 is run from CLI...counter-intuitive for embedding)

o Added handling for new @requiresDirectInvocation (generation/parsing, MojoDescriptor support, etc.)

o Added check in DefaultLifecycleExecutor to throw a LifecycleExecutionException if a mojo specified in a lifecycle binding is marked as direct-invocation only.

o Added MavenProjectHelper/DefaultMavenProjectHelper to provide convenience methods for manipulating MavenProject instances (for example, attaching artifacts or adding resources)

o Removed maven-artifact dependency from maven-source-plugin, and added dependency on maven-plugin-api (should've been there)



git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@233021 13f79535-47bb-0310-9956-ffa450edef68
2005-08-16 18:03:20 +00:00
John Dennis Casey fe5a91b0d6 Working on: MNG-483
Fixing profile application to separate profiles discovered in and around POM from those in settings.xml, and apply them separately in the order: 

for-each-project-in-inheritance:{POM, profiles.xml}, settings.xml

Added common interface for accumulating, explicitly activating and deactivating, and retrieving profiles to be applied to a given project. This manager interface (ProfileManager) is general enough to be applicable to both the project-level and settings-level profiles.

Added 'performRelease'-keyed profile to super-POM which will be used by the release plugin and anyone using a parallel process, and which will enable '-DupdateReleaseInfo=true' for the deploy mojo, along with enabling the source attachment for the project.

Added 'attach' parameter to JarSourceMojo to allow local POM to turn off source attachments, overriding release profile in super-pom.

Updated the release:perform mojo to use '-DperformRelease=true' for switching on the new release profile, rather than just using '-DupdateReleaseInfo=true'...



git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@233013 13f79535-47bb-0310-9956-ffa450edef68
2005-08-16 16:31:02 +00:00
John Dennis Casey 531c1c4f79 Applying patch from Jason Grant for unpacking assemblies and for attaching assemblies as attached artifacts - Thanks, Jason
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@233012 13f79535-47bb-0310-9956-ffa450edef68
2005-08-16 16:21:39 +00:00
Vincent Siveton 6db6fb8909 MNG-722: Applied changes proposed by Incze Lajos, ie using OutputStreamWriter(FileOutputStream(...), outputEncoding) instead of FileWriter(...). Added also the outputEncoding parameter in the default-site.xml.
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@232989 13f79535-47bb-0310-9956-ffa450edef68
2005-08-16 12:47:25 +00:00
Trygve Laugstol b584a47541 o Removing comment about no contributors.
o Changing the promt from "$>" to "$ ".


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@232887 13f79535-47bb-0310-9956-ffa450edef68
2005-08-15 21:38:11 +00:00
Kenney Westerhof ef2ef62898 Added integration test to prove MNG-739 cannot be reproduced.
Btw, FIXME: should we, if just one include is given, take that
as the only include, or add it to the default include of **/*Test.java?


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@232852 13f79535-47bb-0310-9956-ffa450edef68
2005-08-15 18:47:28 +00:00
Trygve Laugstol 4de1c8c892 Fixing MNG-623: "Improve the exclusion / inclusion of a dependency inside the
ear"
Committing on behalf of Stephane Nicoll.
Provides two new flags to customize ear modules: 

* excluded ; if set the module is not bundle in the EAR file 
* library ; if set the java module is considered as a 3rd party library and no
  entry is generated in the application.xml 
 
The patch also update the documentation.


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@232833 13f79535-47bb-0310-9956-ffa450edef68
2005-08-15 16:46:12 +00:00
Trygve Laugstol 4f377df0f9 Fixing MNG-737.
o Correcting the groupId of the plugin.


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@232832 13f79535-47bb-0310-9956-ffa450edef68
2005-08-15 16:39:20 +00:00
Trygve Laugstol 0a99cab561 o Improving the 'related projects' section.
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@232831 13f79535-47bb-0310-9956-ffa450edef68
2005-08-15 16:32:16 +00:00
Brett Leslie Porter bda3808ae5 fix the integration test after the default location changed
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@232798 13f79535-47bb-0310-9956-ffa450edef68
2005-08-15 11:47:18 +00:00
Vincent Massol a10ae839cb MNG-736: Move ear source directory to comply with other plugin's structure. Applied on Stephane's behalf.
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@232787 13f79535-47bb-0310-9956-ffa450edef68
2005-08-15 10:37:30 +00:00
Vincent Massol 1fe703883e MNG-150: Create a rar mojo. Applied on behalf of snicoll.
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@232602 13f79535-47bb-0310-9956-ffa450edef68
2005-08-14 13:19:12 +00:00
Kenney Westerhof aefdc2b95d Set project's basedir on the ant Target so relative paths
work.


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@232502 13f79535-47bb-0310-9956-ffa450edef68
2005-08-13 15:04:18 +00:00
Kenney Westerhof f14a81d454 Moved execution code to abstract base class, so other ant-enabled plugins
may use this more easily.


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@232501 13f79535-47bb-0310-9956-ffa450edef68
2005-08-13 15:01:24 +00:00
Kenney Westerhof 59128be85b Making sure there is always a filter present, to prevent malfunctioning
plugin configuration code disabling running any tests.


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@232500 13f79535-47bb-0310-9956-ffa450edef68
2005-08-13 14:58:04 +00:00
John Dennis Casey 88d49cb04f o Improving toString for Dependency in the 4.0.0 version codeSegment in maven.mdo
o Improving error messages for ResourceDoesNotExistException in the transformations
o Adding specificity to the dependency validation stuff, to output which dependency is offending...
o Added it1013 to show off the new dependency validation stuff.


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@232399 13f79535-47bb-0310-9956-ffa450edef68
2005-08-12 21:55:00 +00:00
John Dennis Casey 155c0a69a7 Resolving: MNG-686...Moving <directory/> specification from Build to BuildBase to allow profiles inline within the POM to change this setting.
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@232336 13f79535-47bb-0310-9956-ffa450edef68
2005-08-12 17:06:38 +00:00
Kenney Westerhof 1311273aa6 Made buildTopDownMergedConfiguration really recursive - in most cases it didn't.
Fixed a merge problem where only direct children of <configuration> in the POM
appeared in the merged configuration.

(like maven-antrun-plugin, the 'tasks' configuration tag didn't have any
value, but has children. After the merge, the children were gone,
and it was marked as having no value, and hence the field was not updated.)


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@232281 13f79535-47bb-0310-9956-ffa450edef68
2005-08-12 12:44:22 +00:00
John Dennis Casey 0b4aa2dc41 Resolving: MNG-715
PluginParameterExpressionEvaluator now has two static final Maps - BANNED_EXPRESSIONS and DEPRECATED_EXPRESSIONS, each of which contain mappings of restricted expressions to the preferred alternative.



git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@232200 13f79535-47bb-0310-9956-ffa450edef68
2005-08-12 04:03:33 +00:00
John Dennis Casey 9c5979f46b Adding description for it1012
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@232191 13f79535-47bb-0310-9956-ffa450edef68
2005-08-12 03:04:06 +00:00
John Dennis Casey cb41f94717 Resolving: MNG-652
o Adding it1012 that should express the throwing of LifecycleExecutionException for unknown packaging.



git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@232189 13f79535-47bb-0310-9956-ffa450edef68
2005-08-12 03:02:35 +00:00
Brett Leslie Porter ddf74d6ad5 check we get a report out of surefire
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@232186 13f79535-47bb-0310-9956-ffa450edef68
2005-08-12 02:45:57 +00:00
John Dennis Casey 26de9f77d0 Fixing problem with mojo configuration merges between parameter configuration keyed by alias and by name within the POM, along with configuration within the MojoDescriptor.
Also adding an IT that will indirectly test that default parameter values are not being disturbed during the merge process.


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@232185 13f79535-47bb-0310-9956-ffa450edef68
2005-08-12 02:25:26 +00:00
John Dennis Casey 86321f4163 Adding comment to discourage re-adding the status inheritance.
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@232178 13f79535-47bb-0310-9956-ffa450edef68
2005-08-12 01:43:36 +00:00
John Dennis Casey 0db68a8c2e Removing inheritance of status in distributionManagement.
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@231555 13f79535-47bb-0310-9956-ffa450edef68
2005-08-12 01:36:55 +00:00
John Dennis Casey 3408c163dc o Removed it0048, and replaced it with a unit test for the DefaultProfileInjector.
o Reverted the logic of the DefaultProfileInjector to merge-and-override the model, with the profile being dominant
o Added merging for distributionManagement and modules (conditionally, based on flag) in the modelBase merge
o Refactored the override logic into a couple of methods in ModelUtils to make it easier to understand what's going on here.
o Verified that both the build and the model itself are being merged correctly during profile injection, with profile dominance, but persistence of changes to the model.


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@231481 13f79535-47bb-0310-9956-ffa450edef68
2005-08-11 16:46:19 +00:00
Trygve Laugstol 9fa2ff16f6 o Updating to the latest Plexus compiler API.
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@231478 13f79535-47bb-0310-9956-ffa450edef68
2005-08-11 16:14:18 +00:00
Kenney Westerhof c897fa04c1 After r231121 the <modules/> in poms were ignored. I tracked the changes,
and it was obvious: merge code didn't merge the Modules section, and possibly
other sections aswell. Also putting all normal model build info in a profile and
then copying profile data back to the model seemed odd to me. Now only
data from profiles that actually get merged is merged.


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@231470 13f79535-47bb-0310-9956-ffa450edef68
2005-08-11 14:35:20 +00:00
Vincent Siveton a133047280 MNG-722: added a new outputEncoding parameter in the DoxiaMojo class. Updated the maven-site.vm
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@231433 13f79535-47bb-0310-9956-ffa450edef68
2005-08-11 12:28:52 +00:00
Brett Leslie Porter 2c9f839105 add pre build hook to remove the core it plugin so it is always updated
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@231401 13f79535-47bb-0310-9956-ffa450edef68
2005-08-11 05:14:58 +00:00
John Dennis Casey 3c53a1305d Resolving: MNG-674
o Added it0049 to prevent further regressions. ;)


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@231393 13f79535-47bb-0310-9956-ffa450edef68
2005-08-11 04:38:46 +00:00
Kenney Westerhof 309f26b810 Sometimes plugins get added in an unofficial way - the pluginDiscovererManager
sees the plugin and marks it as 'installed' (it's in a hashtable somewhere).
The official way is to go through verifyPlugin. That gets called later on
for that plugin, which only calls addPlugin (that registers, resolves,
and, most importantly, creates a childContainer for that plugin!) IF
the plugin is NOT yet registered.

Since it is registered in the hashtable, but no childRealm was made there,
addPlugin doesn't get called. Added a simple check to ALSO call 'addPlugin'
if it was added to the hashtable. Side effect is that the version that
was normally going to be used is now used and overrides the other version.

This really needs a cleanup!

Committing anyway:

01:26<trygvis> right now I think we're allowed to push over old ladies and
               steal candy from small children to get this to work



git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@231353 13f79535-47bb-0310-9956-ffa450edef68
2005-08-10 23:31:40 +00:00
John Dennis Casey 013d4039fb Resolving: MNG-684
o Split profile injection out into its own component away from the defaults assembler
o Moved code common to the defaults assembler and the profile injector into ModelUtils
o Removed the profile-related method from ModelIntheritanceAssembler
o added it0048 to test that profile values will override POM values.



git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@231294 13f79535-47bb-0310-9956-ffa450edef68
2005-08-10 19:21:34 +00:00
Trygve Laugstol 6db67ef76e o Adding a part on how to get into development of m2 itself.
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@231258 13f79535-47bb-0310-9956-ffa450edef68
2005-08-10 15:06:03 +00:00
Kenney Westerhof 7fa0cc72c3 Donating maven-antrun-plugin to the Maven2 project, as discussed with Brett.
Enjoy! :-)

TODO:

o make <echo>...</echo> output visible.

o devise a way to pass on maven2 properties to <ant/>-called build.xml files.
  The ant code just copies all properties from the default PropertyHandler,
  however with m2 that's not possible since they are resolved/evaluated at
  runtime.


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@231230 13f79535-47bb-0310-9956-ffa450edef68
2005-08-10 13:38:21 +00:00
Brett Leslie Porter 53865c867f add a basic C# plugin using the Ant tasks
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@231226 13f79535-47bb-0310-9956-ffa450edef68
2005-08-10 13:12:25 +00:00
Kenney Westerhof ad947569c8 MNG-692, continued: also update project.artifact.file for War.
I'm leaving it alone for non-war (i.e. exploded/inplace webapp) generation.


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@231199 13f79535-47bb-0310-9956-ffa450edef68
2005-08-10 09:16:23 +00:00
Brett Leslie Porter d401ffe655 add a test case to illustrate why we have to make compile time dependencies transitive as compile, not runtime as we'd like.
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@231142 13f79535-47bb-0310-9956-ffa450edef68
2005-08-09 23:31:14 +00:00
John Dennis Casey acf7e6f1f8 Correcting problem with originalModel being reset inside processProjectLogic(..) in DefaultMavenProjectBuilder
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@231121 13f79535-47bb-0310-9956-ffa450edef68
2005-08-09 21:44:54 +00:00
John Dennis Casey 9b92bf860e Adding better handling for originalModel in MavenProject.
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@231112 13f79535-47bb-0310-9956-ffa450edef68
2005-08-09 20:56:12 +00:00
John Dennis Casey 0f9196a83d Resolving: MNG-608 (deprecate for now, remove later...notes in TODOs)
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@231084 13f79535-47bb-0310-9956-ffa450edef68
2005-08-09 19:26:24 +00:00
Trygve Laugstol ec2da14433 o Setting svn ignores.
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@231065 13f79535-47bb-0310-9956-ffa450edef68
2005-08-09 17:13:40 +00:00
Trygve Laugstol 0afba79871 o Updating WRT the latest plexus-api.
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@231064 13f79535-47bb-0310-9956-ffa450edef68
2005-08-09 17:03:55 +00:00
John Dennis Casey 1e1efffcba Resolving: MNG-592 (again)
o Modified the PluginMappingDeployMojo in maven-plugin-plugin to always deploy the plugins.xml regardless. This may be a bit heavy, but it avoids the snag with the plugins.xml being detected in the local repository after the install phase runs...plugin mappings weren't making it to the repository during deploy.

o Added a new series of IT: it2xxx which will be tests that require more than a single maven invocation, and will be run via shell script, at least for now. This one builds and deploys a plugin, then attempts to use the plugin by referencing the prefix mapping in the (non-central) remote repository.



git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@231058 13f79535-47bb-0310-9956-ffa450edef68
2005-08-09 16:11:40 +00:00
Brett Leslie Porter 70eadfd14d if a version part has a leading 0, fallback to string comparison but to retain the extra 0.
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@231016 13f79535-47bb-0310-9956-ffa450edef68
2005-08-09 09:18:08 +00:00
Trygve Laugstol 16bbbbdd91 o Adding a piece about dependency management.
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@230934 13f79535-47bb-0310-9956-ffa450edef68
2005-08-09 00:20:31 +00:00
Trygve Laugstol 80c945fd82 o Setting ignores.
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@230933 13f79535-47bb-0310-9956-ffa450edef68
2005-08-09 00:20:09 +00:00
John Dennis Casey 09ebb0f615 Resolving: MNG-163
Use MavenProject.addResource(..) and .addTestResource(..) to perform this function. I've built a BuildOverlay to insulate the interpolated, initialized Model's Build instance from runtime changes to these, in a similar fashion to addCompileSourceRoots(..), because I wanted to preserve some compat with plugins using ${project.build.resources}.


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@230920 13f79535-47bb-0310-9956-ffa450edef68
2005-08-08 23:06:48 +00:00
Trygve Laugstol daba7dca27 Resolving http://jira.codehaus.org/browse/MNG-710: "Add ability to fork the
maven-compiler-plugin".
o Applying Rod Coffin's patch. Removed the basedir as a configurable argument.


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@230869 13f79535-47bb-0310-9956-ffa450edef68
2005-08-08 19:58:32 +00:00
Kenney Westerhof 2823fe4711 Solving MNG-711:
o Added a check in MavenProject.getArtifacts() to never return null,
  but an empty Set, since there's almost no checking.

o Added requiresDependencyResolution test to SurefirePlugin.


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@230827 13f79535-47bb-0310-9956-ffa450edef68
2005-08-08 17:55:21 +00:00