Re: [mevenide-user] NetBeans "Build" from the Command Line

"Laurent Forêt" <[email protected]> Sat, 7 Jun 2008 21:59:36 +0200
Newsgroups gmane.comp.jakarta.turbine.maven.mevenide.user
Message-ID <[email protected]>
Accroding to your log, it  seems that the command line launched from
netbeans is :

mvn install assembly:directory

You probably use the assembly plugin, it should appear in your pom.xml in
the "plugins" description part .

Laurent



On Sat, Jun 7, 2008 at 3:14 PM, Bob F <[email protected]> wrote:

> [Sorry for the repeat message.  For some strange reason, my email client
> munged my logs into an unreadable format.]
>
>
> Thanks.  When I look at the "Actions" under "Properites", I see that "Build
> project" is linked to "install"; I haven't changed this from the default.
>  It is also set to use the internal Maven, which I also did not change.
>
> Now I run an experiment that shows that something OTHER than an "mvn
> install" is happening when I do a "Build."  Notice that both the console
> output and the result (as seen by "ls target") are different between the
> two.
>
> Help..??????
>
> -- Bob
>
> $ mvn clean
>
> $ ls target
> ls: target: No such file or directory
>
> $ mvn install
>
> [INFO] Scanning for projects...
> [INFO]
> ------------------------------------------------------------------------
> [INFO] Building jangomail
> [INFO]    task-segment: [install]
> [INFO]
> ------------------------------------------------------------------------
> [INFO] [resources:resources]
> [INFO] Using default encoding to copy filtered resources.
> [INFO] [compiler:compile]
> [INFO] Compiling 130 source files to
> /Users/citibob/mvn/jangomail/target/classes
> [INFO] [resources:testResources]
> [INFO] Using default encoding to copy filtered resources.
> [INFO] [compiler:testCompile]
> [INFO] Nothing to compile - all classes are up to date
> [INFO] [surefire:test]
> [INFO] No tests to run.
> [INFO] [jar:jar]
> [INFO] Building jar:
> /Users/citibob/mvn/jangomail/target/jangomail-1.0-LATEST.jar
> [INFO] [install:install]
> [INFO] Installing
> /Users/citibob/mvn/jangomail/target/jangomail-1.0-LATEST.jar to
> /Users/citibob/.m2/repository/com/jangomail/jangomail/1.0-LATEST/jangomail-1.0-LATEST.jar
> [INFO]
> ------------------------------------------------------------------------
> [INFO] BUILD SUCCESSFUL
> [INFO]
> ------------------------------------------------------------------------
> [INFO] Total time: 4 seconds
> [INFO] Finished at: Sat Jun 07 09:04:57 EDT 2008
> [INFO] Final Memory: 7M/24M
> [INFO]
> ------------------------------------------------------------------------
>
> $ ls targetclasses
> maven-archiverjangomail-1.0-LATEST.jar
> $ [Now I do a "Build" in NetBeans]
>
> Scanning for projects...
>
> ----------------------------------------------------------------------------
> Building jangomail
>   task-segment: [install]
>
> ----------------------------------------------------------------------------
> project-execute
> artifact org.apache.maven.plugins:maven-resources-plugin: checking for
> updates from netbeansIDE-repo-internal
> artifact org.apache.maven.plugins:maven-compiler-plugin: checking for
> updates from netbeansIDE-repo-internal
> artifact org.apache.maven.plugins:maven-surefire-plugin: checking for
> updates from netbeansIDE-repo-internal
> artifact org.apache.maven.plugins:maven-jar-plugin: checking for updates
> from netbeansIDE-repo-internal
> Ignoring available plugin update: 2.2 as it requires Maven version 2.0.6
> artifact org.apache.maven.plugins:maven-install-plugin: checking for
> updates from netbeansIDE-repo-internal
> artifact org.apache.maven.plugins:maven-assembly-plugin: checking for
> updates from netbeansIDE-repo-internal
> [resources:resources]
> Using default encoding to copy filtered resources.
> [compiler:compile]
> Nothing to compile - all classes are up to date
> [resources:testResources]
> Using default encoding to copy filtered resources.
> [compiler:testCompile]
> Nothing to compile - all classes are up to date
> [surefire:test]
> No tests to run.
> [jar:jar]
> Building jar: /Users/citibob/mvn/jangomail/target/jangomail-1.0-LATEST.jar
> Preparing assembly:directory
>
> ----------------------------------------------------------------------------
> Building jangomail
>
> ----------------------------------------------------------------------------
> [WARN]Removing: directory from forked lifecycle, to prevent recursive
> invocation.
> [resources:resources]
> Using default encoding to copy filtered resources.
> [compiler:compile]
> Nothing to compile - all classes are up to date
> [resources:testResources]
> Using default encoding to copy filtered resources.
> [compiler:testCompile]
> Nothing to compile - all classes are up to date
> [surefire:test]
> No tests to run.
> [jar:jar]
> [WARN]DEPRECATED [descriptor]: Please use descriptors instead
> [assembly:directory {execution: nb}]
> Processing DependencySet (output=lib)
> Copying 14 files to
> /Users/citibob/mvn/jangomail/target/executable-netbeans.dir
> [install:install]
> Installing /Users/citibob/mvn/jangomail/target/jangomail-1.0-LATEST.jar to
> /Users/citibob/.m2/repository/com/jangomail/jangomail/1.0-LATEST/jangomail-1.0-LATEST.jar
> ------------------------------------------------------------------------
> BUILD SUCCESSFUL
> ------------------------------------------------------------------------
> Total time: 3 seconds
> Finished at: Sat Jun 07 09:07:23 EDT 2008
> Final Memory: 74M/155M
> ------------------------------------------------------------------------
>
> $ ls target
> archive-tmp                     jangomail-1.0-LATEST.jarclasses
> maven-archiverexecutable-netbeans.dir
>
>
>
>
>
> On Jun 7, 2008, at 4:07 AM, Laurent Forêt wrote:
>
>> Right click on your project and select "Properties". In the left Panel of
>> the customizer select "actions". In the right Panel, select the "build
>> project" action, you will see the maven mapping goals for the "build"
>> action.
>> Maybe you have a profile activated.
>>
>> Laurent  .
>>
>> On Fri, Jun 6, 2008 at 11:28 PM, Marek Nowicki <[email protected]>
>> wrote:
>> I checked it in ProcessExplorer and when I "Build" NetBeans run:
>> $ cmd /c ""C:\Program Files\Apache Software
>> Foundation\apache-maven-2.0.9\bin\mvn.bat" -Dfile.encoding=utf-8 install"
>>
>> regards,
>> Marek
>>
>> Dnia 06-06-2008 o 23:20:23 Bob F <[email protected]> napisał:
>>
>> I'm sorry, I don't think I was clear.
>>
>> What I want to do is figure out the standard Maven command line to
>> use to do the equivalent of "Build".  But I want to do it in plain
>> Maven from the command line, no NetBeans involved.  This will allow
>> me to give Maven+NetBeans projects to other people and have them
>> compile without installing NetBeans.
>>
>> Thanks,
>> -- Bob
>>
>> On Jun 6, 2008, at 5:13 PM, Anuradha G wrote:
>>
>> You can use  right click on project "Custom" - > Goals and type
>> build on goal
>>
>> On Sat, Jun 7, 2008 at 2:21 AM, Bob F <[email protected]> wrote:
>> Hello,
>>
>> I use NetBeans 6.0 + MevenIDE.  It works pretty well.  I just use
>> the standard Maven archetype, I don't mess with the POM file at all.
>>
>> I want to be able to do anything I do within NetBeans from the
>> Command Line.  For example, if I right-click on my project and
>> choose "Clean", that's the same as doing "mvn clean".
>>
>> Unfortunately, I cannot find the equivalent to the "Build" NetBeans
>> command.  It should do an "mvn install", and also create the target/
>> executable-netbeans.dir directory.  The closest I've come is:
>>
>> mvn -Dexecution=nb assembly:directory -Ddescriptor=src/main/
>> assemblies/netbeans-run.xml
>>
>> But this does not create .jar files with proper dependencies.
>>
>> Help...
>>
>> Thanks,
>> -- Bob
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe from this list, please visit:
>>
>>  http://xircles.codehaus.org/manage_email
>>
>>
>>
>>
>>
>> --
>> Anuradha G
>>
>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe from this list, please visit:
>>
>>  http://xircles.codehaus.org/manage_email
>>
>>
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
>
>   http://xircles.codehaus.org/manage_email
>
>
>