Re: svn commit: r519796 - in /maven/doxia/trunk/doxia-core/src: main/java/org/apache/maven/doxia/validation/ test/java/org/apache/maven/doxia/validation/

2007-03-19 Thread Juan F. Codagnone
On Sunday 18 March 2007 23:23, [EMAIL PROTECTED] wrote:
> Author: jvanzyl
> Date: Sun Mar 18 19:23:13 2007
> New Revision: 519796
>
> URL: http://svn.apache.org/viewvc?view=rev&rev=519796
> Log:
> o removing dead code that i put in with the twiki code
>
>
> Removed:
>
> maven/doxia/trunk/doxia-core/src/main/java/org/apache/maven/doxia/validatio
>n/
> maven/doxia/trunk/doxia-core/src/test/java/org/apache/maven/doxia/validatio
>n/

The validation packages was not dead code "per se"... No class inside doxia 
was using it, but in my case, the AdvicedSink turned into a useful class to 
debug and test parsers in a development environment.




pgpIxblPNSZaw.pgp
Description: PGP signature


Re: Stuck ! (was Re: Doxia module)

2006-08-24 Thread Juan F. Codagnone
Hi Arnaud,

I think that what you are missing is to add an  to your pom.
For example for twiki (is not distributed in maven-2.0.4) i do:

did you tried to put something like
  
...

 
   org.apache.maven.doxia
   doxia-module-muse
   
 

...
  
into your pom?

your jar has the plexus xml? 
you have plexus annotations like 
http://svn.apache.org/repos/asf/maven/doxia/trunk/doxia-modules/doxia-module-confluence/src/main/java/org/apache/maven/doxia/module/confluence/ConfluenceParser.java
 
and  
http://svn.apache.org/repos/asf/maven/doxia/trunk/doxia-modules/doxia-module-confluence/src/main/java/org/apache/maven/doxia/module/confluence/ConfluenceSiteModule.java
 ?

Juan.



On Monday 14 August 2006 11:42, Arnaud Bailly wrote:
> Hello,
> I still have troubles with doxia while trying to add a new module. I
> can see from posts in the users list that other people have troubles
> with using non standard modules like twiki.
>
> I tried copying my muse module to doxia-modules, it works fine and
> compiles ok, but I am left with the problem of telling maven to use my
> version of doxia. I could think of various solutions to this problem,
> including full recompilation of maven with modified dependency but I
> dont think this is the rigth way: there must be a way to add a plexus
> component to a system without recompiling everything. After all, this
> is the whole point of component based software engineering !
>
> So I am asking my question again: How can I add a new module
> (ie. input file format) to doxia in such a way that this format can be
> used to document a project in maven ? I suspect this has something to
> do with injecting a new plexus component, which may be something that
> is done when a jar or classpath entry is loadedd ( ? maybe through
> classworlds).
>
> Any insights into this would be greatly appreciated as I desperately
> want  this plugin to work.
>
> thx,


pgpK3JlfRt3ui.pgp
Description: PGP signature


[PATCH] some twiki patches

2006-08-22 Thread Juan F. Codagnone
Hi,

I have some random fixes for the twiki parser  (table related) and for the 
rest of the Sinks.

juanpatches.diff is the whole diff, and the juanpatches.tar.gz has the 
incrementals patches with a comment.

Regards,
   Juan.


r2 | juan | 2006-08-20 22:16:12 -0300 (Sun, 20 Aug 2006) | 4 lines
Changed paths:
   
M 
/branches/433103/doxia-core/src/main/java/org/apache/maven/doxia/module/latex/LatexSink.java

document start should be the first thing in a \latex file.

(if not it triggers ! LaTeX Error: \usepackage before \documentclass.)


r3 | juan | 2006-08-20 22:18:55 -0300 (Sun, 20 Aug 2006) | 5 lines
Changed paths:
   
M 
/branches/433103/doxia-modules/doxia-module-twiki/src/main/java/org/apache/maven/doxia/module/twiki/parser/SectionBlock.java

twiki parser generated sectionTitle events in all the sections. 
The only Sink that supports that behavior is xdoc.

 Now it generates sectionTitle1, sectionTitle2, ...


r6 | juan | 2006-08-21 00:49:33 -0300 (Mon, 21 Aug 2006) | 1 line
Changed paths:
   
M 
/branches/433103/doxia-modules/doxia-module-twiki/src/main/java/org/apache/maven/doxia/module/twiki/parser/TableBlock.java

Sink#tableRows must be called after Sink#table and before Sink#tableRow

r7 | juan | 2006-08-21 00:50:02 -0300 (Mon, 21 Aug 2006) | 1 line
Changed paths:
   
M 
/branches/433103/doxia-core/src/main/java/org/apache/maven/doxia/validation/AdvicedSink.java

dupe

r8 | juan | 2006-08-21 01:03:09 -0300 (Mon, 21 Aug 2006) | 1 line
Changed paths:
   
M 
/branches/433103/doxia-core/src/main/java/org/apache/maven/doxia/module/latex/LatexSink.java

implement tableCell and tableCell_

r9 | juan | 2006-08-21 01:15:30 -0300 (Mon, 21 Aug 2006) | 1 line
Changed paths:
   
M 
/branches/433103/doxia-core/src/main/java/org/apache/maven/doxia/module/rtf/RtfSink.java

implement tableHeaderCell and tableHeaderCell_ to avoid NPE

r10 | juan | 2006-08-21 01:33:30 -0300 (Mon, 21 Aug 2006) | 1 line
Changed paths:
   
M 
/branches/433103/doxia-modules/doxia-module-twiki/src/main/java/org/apache/maven/doxia/module/twiki/parser/TableBlock.java

something was wrong in rev6.

r11 | juan | 2006-08-21 01:41:12 -0300 (Mon, 21 Aug 2006) | 1 line
Changed paths:
   
M 
/branches/433103/doxia-modules/doxia-module-confluence/src/main/java/org/apache/maven/doxia/module/confluence/parser/table/TableBlock.java

port revisions 6 and 10 to confluence.





juanpatches.tar.gz
Description: GNU Zip compressed data
Index: doxia-core/src/main/java/org/apache/maven/doxia/module/rtf/RtfSink.java
===
--- doxia-core/src/main/java/org/apache/maven/doxia/module/rtf/RtfSink.java	(revision 42)
+++ doxia-core/src/main/java/org/apache/maven/doxia/module/rtf/RtfSink.java	(working copy)
@@ -854,6 +854,16 @@
 table.add( row );
 }
 
+public void tableHeaderCell()
+{
+tableCell();
+}
+   
+public void tableHeaderCell_()
+{
+tableCell_();
+}
+
 public void tableCell()
 {
 cell = new Cell();
Index: doxia-core/src/main/java/org/apache/maven/doxia/module/latex/LatexSink.java
===
--- doxia-core/src/main/java/org/apache/maven/doxia/module/latex/LatexSink.java	(revision 42)
+++ doxia-core/src/main/java/org/apache/maven/doxia/module/latex/LatexSink.java	(working copy)
@@ -130,12 +130,12 @@
 
 if ( !fragmentDocument )
 {
+markup( getDocumentStart() );
+
 markup( sinkCommands );
 
 markup( preamble );
 
-markup( getDocumentStart() );
-
 markup( getDocumentBegin() );
 }
 }
@@ -432,11 +432,12 @@
 public void tableRow_()
 {
 markup( "" + EOL );
-if ( gridFlag )
+if ( gridFlag || lastCellWasHeader )
 {
 markup( "\\hline" + EOL );
 }
 cellCount = 0;
+lastCellWasHeader = false;
 }
 
 public void title()
@@ -576,6 +577,30 @@
 
 public void tableCell()
 {
+tableCell( false );
+}
+
+public void tableCell_()
+{
+tableCell_( false );
+}
+
+public void tableHeaderCell()
+{
+tableCell( true );
+}
+
+public void tableHeaderCell_()
+{
+tableCell_( true );
+}
+

Re: [vote] Release Maven 2.0.3 (third RC)

2006-03-20 Thread Juan F. Codagnone
so far, so good 

On Saturday 11 March 2006 03:00, dan tran wrote:
> I am currently using 2.0.3 snapshot(s) in my production build.
> So far all my builds work great
>
> +1 and looking forward to the release.
>
> -Dan
>
> On 3/10/06, Wayne Fay <[EMAIL PROTECTED]> wrote:
> > Well I did say "correct me if I'm wrong"... ;-)
> >
> > Thanks for the education, Brett.
> >
> > Wayne
> >
> > On 3/10/06, Brett Porter <[EMAIL PROTECTED]> wrote:
> > > http://www.apache.org/foundation/voting.html
> > >
> > > Actually, it's just PMC members. They are the ones with the authority
> > > to make a release official.
> > >
> > > Of course, we like to hear from everyone that has tested something to
> > > confirm whether it is working or not.
> > >
> > > - Brett
> > >
> > > Wayne Fay wrote:
> > > > Correct me if I'm wrong... but I'm pretty certain non-binding votes
> > > > are when "people who aren't official Maven devs but happen to
> > > > subscribe to this list" (like me) feel like voting on dev issues. 
> > > > ;-)
> > > >
> > > > Edwin, you're a "real Maven dev" so your votes on an issue are always
> >
> > "binding".
> >
> > > > Wayne
> > >
> > > -
> > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > For additional commands, e-mail: [EMAIL PROTECTED]


pgpEhvXsp1gO4.pgp
Description: PGP signature


[jira] Commented: (MNG-1827) mvn cli bash script doesn't work in mingw

2006-03-07 Thread Juan F. Codagnone (JIRA)
[ http://jira.codehaus.org/browse/MNG-1827?page=comments#action_60427 ] 

Juan F. Codagnone commented on MNG-1827:


no one use msys to launch maven in windows?

> mvn cli bash script  doesn't work  in mingw
> ---
>
>  Key: MNG-1827
>  URL: http://jira.codehaus.org/browse/MNG-1827
>  Project: Maven 2
> Type: Bug

> Versions: 2.0, 2.0.1
>  Environment: http://www.mingw.org/ under windows.
> Reporter: Juan F. Codagnone
>  Attachments: MNG-1827.diff, MNG-1827.diff
>
>
> mvn does not work if it is lunched from the bash that comes in the msys migwn 
> environment.

-- 
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
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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



[jira] Created: (MAVENUPLOAD-635) upload hibernate-annotations-3.1beta7

2005-12-15 Thread Juan F. Codagnone (JIRA)
upload hibernate-annotations-3.1beta7
-

 Key: MAVENUPLOAD-635
 URL: http://jira.codehaus.org/browse/MAVENUPLOAD-635
 Project: maven-upload-requests
Type: Wish

Reporter: Juan F. Codagnone


Now that hibernate 3.1 is in ibliblio (MAVENUPLOAD-630) it would nice to have 
hibernate-annotations-3.1beta7 (beta5 worked against rc but not with final).

(i compiled and have it in my local repository, but it would nice for 
completness.


-- 
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
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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



[jira] Updated: (MNG-1827) mvn cli bash script doesn't work in mingw

2005-12-13 Thread Juan F. Codagnone (JIRA)
 [ http://jira.codehaus.org/browse/MNG-1827?page=all ]

Juan F. Codagnone updated MNG-1827:
---

Attachment: MNG-1827.diff

> mvn cli bash script  doesn't work  in mingw
> ---
>
>  Key: MNG-1827
>  URL: http://jira.codehaus.org/browse/MNG-1827
>  Project: Maven 2
> Type: Bug

> Versions: 2.0, 2.0.1
>  Environment: http://www.mingw.org/ under windows.
> Reporter: Juan F. Codagnone
>  Attachments: MNG-1827.diff, MNG-1827.diff
>
>
> mvn does not work if it is lunched from the bash that comes in the msys migwn 
> environment.

-- 
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
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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



[jira] Updated: (MNG-1827) mvn cli bash script doesn't work in mingw

2005-12-13 Thread Juan F. Codagnone (JIRA)
 [ http://jira.codehaus.org/browse/MNG-1827?page=all ]

Juan F. Codagnone updated MNG-1827:
---

Attachment: MNG-1827.diff

> mvn cli bash script  doesn't work  in mingw
> ---
>
>  Key: MNG-1827
>  URL: http://jira.codehaus.org/browse/MNG-1827
>  Project: Maven 2
> Type: Bug

> Versions: 2.0, 2.0.1
>  Environment: http://www.mingw.org/ under windows.
> Reporter: Juan F. Codagnone
>  Attachments: MNG-1827.diff
>
>
> mvn does not work if it is lunched from the bash that comes in the msys migwn 
> environment.

-- 
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
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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



[jira] Created: (MNG-1827) mvn cli bash script doesn't work in mingw

2005-12-13 Thread Juan F. Codagnone (JIRA)
mvn cli bash script  doesn't work  in mingw
---

 Key: MNG-1827
 URL: http://jira.codehaus.org/browse/MNG-1827
 Project: Maven 2
Type: Bug

Versions: 2.0, 2.0.1
 Environment: http://www.mingw.org/ under windows.
Reporter: Juan F. Codagnone



mvn does not work if it is lunched from the bash that comes in the msys migwn 
environment.


-- 
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
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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



[jira] Resolved: (DOXIA-27) sink validation (sink advisor)

2005-12-11 Thread Juan F. Codagnone (JIRA)
 [ http://jira.codehaus.org/browse/DOXIA-27?page=all ]
 
Juan F. Codagnone resolved DOXIA-27:


 Resolution: Fixed
Fix Version: 1.0-alpha-6

Jason commited the files in revision 349241, so i consider that it has been 
fixed. (the only things missings are the two unit tests).


> sink validation (sink advisor)
> --
>
>  Key: DOXIA-27
>  URL: http://jira.codehaus.org/browse/DOXIA-27
>  Project: doxia
> Type: Improvement

> Reporter: Juan F. Codagnone
>  Fix For: 1.0-alpha-6
>  Attachments: DOXIA-27.tar.gz
>
>
> Hi,
>  in the past day i've been writting a twiki parser for doxia. It isn't done 
> yet, but i started to convert some text using existing Sinks, and while doing 
> that i've found some problems:
>   None of the sinks tries to validates a correct usage. For example in most 
> of 
> sinks,
>   sink.list();
>   sint.listItem_();
> would generate an invalid output, and you don't find that until you process 
> the output. I found this a bit fragile.
> To solve it, i've created an AdvicedSink class that is a proxy implementation 
> of a Sink, where you can inject some Advisors to do some crosscutting 
> validations. The advisors are like AOP and you only must implement one method 
> instead of the 89 of the Sink.
> I've implemented two advisors: one that prints the the sink calls with 
> indentation:
> head
> head_
> body
>section1
>   sectionTitle
>  text
> ...
> usefull for debuging, and one that throws a runtime exception if the closing 
> element doesn't match with the starting, in cases like:
>   sink.list();
>   sint.listItem_();
> In the future i would like to see an advisor that check in a fine grain the 
> sink events. For example in the XdocSink if i do
>   sink.listItem();
>   sink.text("foo");
>   sink.listItem_();
> wrong code is generated, and i must do:
>   sink.listItem();
>   sink.paragraph();
>   sink.text("foo");
>   sink._paragraph();
>   sink.listItem_();
> to get the correct content. And state machine advisor would only allow to 
> call 
> paragraph item a listitem and that would be reusable for all the sinks.
> Example of use:
>  final Sink sink = new AdvicedSink(new MethodBeforeAdvice[] {
> new PrintAdvisor(System.out),
> new HangingElementAdvice(),
>  }, new XdocSink(writer));
> I hope you found it usefull as i do. 
> Regards,
> Juan.

-- 
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
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira



TWiki parser

2005-11-16 Thread Juan F. Codagnone

Hi!

We did a java parser for TWiki [http://twiki.org/] that emits Sink messages. 
It doesn't handle all the features, but it support most of the things we use 
in our wiki.

This is implemented in an ad-hoc line-by-line parser (i was too lazy to  
remember the language compiler classes), but i think it is just fine for a  
free language as twiki. 

A disadvantage of line-by-line parser is that you must understand the parsing  
code, and some times it gets tricky. In this case, the parser is distributed 
in several classes for better understanding. The parsers generates a tree of 
Blocks (ease testing), and they can generates the sink messages (next step 
would be to decouple blocks from doxia). Every language feature was 
introduced by a unit test (ala TDD) so it is easy to detect when a change 
breaks something.

We didn't started to use it yet, but i think it is a usefull. If you found  
the code usable, we are looking forward that this code get to the doxia  
project. Being able to connect wiki written doc with a maven project is a 
nice feature...

For now, the code is available at:
   http://www.zauber.com.ar/project/sandbox/svn/trunk/doxia-zauber/
(be patient with the conection)

Any opinion/ suggestion is welcome.

Regards,
   Juan.

ps. attached there is a description of what is supported.

-- 
Buenos Aires, Argentina  23°C with winds at 5 km/h SSW
---+ Twiki Java Parser

---++ Features

This parser of the [[http://www.twiki.org][TWiki]] text format supports most
of http://twiki.org/cgi-bin/view/TWiki/TextFormattingRules formatting commands.

---+++ General

   * Paragraps,
   * Wiki Words
  * WikiWord
  * Web.WikiWord#anchor,  
  * escaped: !WikiWord
   * Forced Links:
  * [[wiki word]]
  * escaped ![[wiki word]]
   * Specific links: 
  * [[http://www.zauber.com.ar][Zauber]],
  * prevention: ![[http://www.zauber.com.ar][Forced links]]
   * Anchors: [[#AnchorEnd][End]]
   * inline urls:
  * http://twiki.org/
   * mailto link:
  * [[mailto:[EMAIL PROTECTED] Mail]]
  * [[mailto:?subject=Hi Hi]]

---+++ Text Format:

   * *bold*
   * _italic_
   * __bold italic__
   * =Fixedfont=
   * ==Bold fixed==

And nested formats like:
   * *bold with _italic_ and some =fixed= and bold*
Make sure there is no space between the text and the bold, italic, or other
indicators (* _ __ = ==).

---+++ Lists

   * items
  * nested items
  * ordered list
 * arabic numerals
1. item
1. item
1. ...
 * uppercase letters
A. item
A. item
A. ...
 * lowercase letters
a. item
a. item
a. ...
 * uppercase roman numerals
A. item
A. item
A. 
 * Uppercase Roman Numerals
I. item
I. item
I. ...
 * Lowercase Roman Numerals
i. item
i. item
i. 

---+++ Separators

Up
---
Down

---+++ Table

 | *A* | *B* | *C* |
 | Foo | bar | Foo |
 | Bar | Foo | bar |
 | Foo | bar | Foo |

---++ Missing things
---+++ Verbating Mode

class CatAnimal {
  void purr() {
  
}


---+++ Definition List
(i don't use it)
   $ Sushi: Japan
  $ Dim Sum: S.F.
   $ Asado: Argentina

---+++ Diable Links


   RedHat &
  SuSE

   
---+++ Html
*  some text

#EndAnchor


TwikiParserTest.pdf
Description: Adobe PDF document


pgpNHw5t862ix.pgp
Description: PGP signature


[jira] Created: (DOXIA-37) LatexSink: NPE when using tableRow()

2005-11-09 Thread Juan F. Codagnone (JIRA)
LatexSink: NPE when using tableRow()


 Key: DOXIA-37
 URL: http://jira.codehaus.org/browse/DOXIA-37
 Project: doxia
Type: Bug
Reporter: Juan F. Codagnone


if tableRow() is called instead of tableRows( int[] justification, boolean grid 
) you get an NPE.

Ej:
...
table
tableRow
   tableCell
  text
   tableCell_
   tableCell
  text
   tableCell_
   tableCell
  text
   tableCell_
tableRow_
tableRow
   tableCell
  text
   tableCell_
   tableCell
  text
   tableCell_
   tableCell
  text
   tableCell_
tableRow_
tableRow
   tableCell
  text
   tableCell_
   tableCell
  text
   tableCell_
   tableCell
  text
   tableCell_
tableRow_
 table_
...

-- 
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
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira



[jira] Updated: (DOXIA-28) XmlWriterXdocSink

2005-11-09 Thread Juan F. Codagnone (JIRA)
 [ http://jira.codehaus.org/browse/DOXIA-28?page=all ]

Juan F. Codagnone updated DOXIA-28:
---

Attachment: XmlWriterXdocSink.java

updated to handle DOXIA-30

> XmlWriterXdocSink
> -
>
>  Key: DOXIA-28
>  URL: http://jira.codehaus.org/browse/DOXIA-28
>  Project: doxia
> Type: Improvement
> Reporter: Juan F. Codagnone
>  Attachments: 1.diff, XmlWriterXdocSink.java, XmlWriterXdocSink.java
>
>
> Hi,
> i implemented an XmlWriterXdocSink (an xdoc sink implementation that use 
> org.codehaus.plexus.util.xml.XMLWriter to output things). The cool thing 
> about using a XMLWriter is that you can use a PrettyPrintXMLWriter and make 
> the output easily readable. The implementation is based on XdocSink.java. I 
> attach the source file and the differences.
> You can use it as: new XmlWriterXdocSink(new PrettyPrintXMLWriter(writer, 
> "ISO-8859-1", null);
> Juan.

-- 
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
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira



Re: svn commit: r320827 - in /maven/components/trunk: maven-artifact-manager/src/main/java/org/apache/maven/artifact/manager/ maven-artifact-manager/src/main/java/org/apache/maven/artifact/repository/

2005-10-14 Thread Juan F. Codagnone
also the wagon is only configured on putRemoteFile but not in getRemoteFile. 
This was my fault and im very ashamed. Sory I will be more carefull.

Regards,
   Juan.

Index: 
maven-artifact-manager/src/main/java/org/apache/maven/artifact/manager/De
faultWagonManager.java
===
--- 
maven-artifact-manager/src/main/java/org/apache/maven/artifact/manager/Defau
ltWagonManager.java (revision 320991)
+++ 
maven-artifact-manager/src/main/java/org/apache/maven/artifact/manager/Defau
ltWagonManager.java (working copy)
@@ -317,6 +317,8 @@
 try
 {
 wagon = getWagon( protocol );
+
+configureWagon( wagon, repository );
 }
 catch ( UnsupportedProtocolException e )


On Friday 14 October 2005 01:52, Juan F. Codagnone wrote:
> On Thursday 13 October 2005 14:49, [EMAIL PROTECTED] wrote:
> > Author: jdcasey
> > Date: Thu Oct 13 10:49:41 2005
> > New Revision: 320827
>
> ...
>
> > +/**
> > + * Applies the server configuration to the wagon
> > + *
> > + * @param wagon the wagon to configure
> > + * @param repository the repository that has the configuration
> > + * @throws ConfigurationException if the wagon can't be configured
> > + */
> > +private void configureWagon( Wagon wagon, ArtifactRepository
> > repository ) +throws WagonConfigurationException
>
> a small thing (but better now than ever!) there is a small typo in the
> throws doc:
>
> Index:
> maven-artifact-manager/src/main/java/org/apache/maven/artifact/manager/Defa
>ultWagonManager.java
> === ---
> maven-artifact-manager/src/main/java/org/apache/maven/artifact/manager/Defa
>ultWagonManager.java (revision 320991)
> +++
> maven-artifact-manager/src/main/java/org/apache/maven/artifact/manager/Defa
>ultWagonManager.java (working copy)
> @@ -697,7 +697,7 @@
>   *
>   * @param wagon the wagon to configure
>   * @param repository the repository that has the configuration
> - * @throws ConfigurationException if the wagon can't be configured
> + * @throws WagonConfigurationException if the wagon can't be
> configured */
>  private void configureWagon( Wagon wagon, ArtifactRepository
> repository ) throws WagonConfigurationException

-- 
Buenos Aires, Argentina   16°C with winds at 11 km/h E


pgp1EQ0LwWmhm.pgp
Description: PGP signature


Re: [vote] new site layout

2005-10-14 Thread Juan F. Codagnone
Hi,

in http://www.codehaus.org/~jvanzyl/maven2/guides/index.html there are two 
links for "Guide to creating a multi-module build", and the last one is 
wrong.

Juan.

On Friday 14 October 2005 17:38, Jason van Zyl wrote:
> Hi,
>
> Just wanted offer out the new site layout for a vote before publishing
> it to the main site:
>
> http://www.codehaus.org/~jvanzyl/maven2/
>
> You'll notice I've reduced the navigation on the left and placed all the
> documentation here:
>
> http://www.codehaus.org/~jvanzyl/maven2/guides/index.html
>
> There are still some documents that need some work but I think this will
> do for the release and I'll keep working on things.
>
> I'd also like to thank David Jackman, Bob Allison, Raphael Pieroni and
> Jay Hartley for their contributions on the documentation front. Much
> appreciated.

-- 
Buenos Aires, Argentina   16°C with winds at 11 km/h E


pgppaPc5CgNb7.pgp
Description: PGP signature


Re: svn commit: r320827 - in /maven/components/trunk: maven-artifact-manager/src/main/java/org/apache/maven/artifact/manager/ maven-artifact-manager/src/main/java/org/apache/maven/artifact/repository/

2005-10-13 Thread Juan F. Codagnone
On Thursday 13 October 2005 14:49, [EMAIL PROTECTED] wrote:
> Author: jdcasey
> Date: Thu Oct 13 10:49:41 2005
> New Revision: 320827
...
> +/**
> + * Applies the server configuration to the wagon
> + *
> + * @param wagon the wagon to configure
> + * @param repository the repository that has the configuration
> + * @throws ConfigurationException if the wagon can't be configured
> + */
> +private void configureWagon( Wagon wagon, ArtifactRepository
> repository ) +throws WagonConfigurationException

a small thing (but better now than ever!) there is a small typo in the throws 
doc:

Index: 
maven-artifact-manager/src/main/java/org/apache/maven/artifact/manager/DefaultWagonManager.java
===
--- 
maven-artifact-manager/src/main/java/org/apache/maven/artifact/manager/DefaultWagonManager.java
 
(revision 320991)
+++ 
maven-artifact-manager/src/main/java/org/apache/maven/artifact/manager/DefaultWagonManager.java
 
(working copy)
@@ -697,7 +697,7 @@
  *
  * @param wagon the wagon to configure
  * @param repository the repository that has the configuration
- * @throws ConfigurationException if the wagon can't be configured
+ * @throws WagonConfigurationException if the wagon can't be configured
  */
 private void configureWagon( Wagon wagon, ArtifactRepository repository )
 throws WagonConfigurationException


-- 
Buenos Aires, Argentina 18°C with winds at 27 km/h ESE


pgptla3zxWkEt.pgp
Description: PGP signature


[jira] Commented: (MNG-1150) be able to configure custom wagon's properties

2005-10-13 Thread Juan F. Codagnone (JIRA)
[ http://jira.codehaus.org/browse/MNG-1150?page=comments#action_48566 ] 

Juan F. Codagnone commented on MNG-1150:


ohh! i forgot to diff the wagon tree! 

> be able to configure custom wagon's properties
> --
>
>  Key: MNG-1150
>  URL: http://jira.codehaus.org/browse/MNG-1150
>  Project: Maven 2
> Type: Improvement
>   Components: maven-artifact
> Reporter: Juan F. Codagnone
> Assignee: John Casey
>  Fix For: 2.0-beta-4
>  Attachments: MNG-1150.diff
>
> Original Estimate: 1 hour
>Time Spent: 1 hour
> Remaining: 0 minutes
>
> It should be allowed to configure the custom settings of each wagon provider. 
> This would give lot of flexiblity to the user to adapt the wagon provider to 
> his environment. 
> For example, in wagon-ssh i would like to configure WAGONSSH-12 settings or 
> in a https wagon i would things related with CA keys and trust.

-- 
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
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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



Re: [Maven Wiki] Update of "MavenDiscussionEclipseIntegration" by JeanMichelGarnier

2005-10-11 Thread Juan F. Codagnone

the page is intended to be in spanish or it should be in english? If it should 
be in spanish i can fix some typos.

On Tuesday 11 October 2005 13:12, Apache Wiki wrote:
> Dear Wiki user,
>
> You have subscribed to a wiki page or wiki category on "Maven Wiki" for
> change notification.
>
> The following page has been changed by JeanMichelGarnier:
> http://wiki.apache.org/maven/MavenDiscussionEclipseIntegration
>
> New page:
> La pesadilla del classpath de Java ...
>
> Por defecto, eclipse añade los jars del
> target/{pom.artefactId}/WEB-INF/lib an el build path ...
>
> === SNAPSHOT ===
>
> Sin snapshot:
>
> Hay un articulo en la web de Eclipse sobre la integration de WST con maven:
> http://www.eclipse.org/webtools/jst/components/j2ee/scenarios/MavenEclipseI
>ntegration.html
>
>  Debug
>
> Fragmento de http://maven.apache.org/reference/plugins/eclipse/:
> Artifact Sources:
> Frequently you will want to include for compiled jars the source .java
> files to help with debugging. The plugin will check if the file specified
> is located in MAVEN_REPO/${groupId}/src/ directory and ending in
> maven.eclipse.src.extension exists and will add it as a source attachment.
> Using default values the dependency
> MAVEN_REPO/eclipse/jars/eclipse-ui-3.0.0.jar will be mapped to
> MAVEN_REPO/eclipse/src/eclipse-ui-3.0.0.zip
>
> Podríamos subir los zips de codigo fuente en nuestro
> http://www.opentrends.net/repository/
>
> Para los servicios de openFrame, podríamos la propiedad
> http://maven.apache.org/reference/plugins/eclipse/
> y añadir una propriedad Eclipse a cada dependency
> 
> group
> artifact
> version
> 
>   true
> 
>   
>
> --> generar .wtpmodules
> **
> Supongo q habías "hacked" el classpath.jelly del maven eclipse plugin para
> tu fichero /openFrame-samples-Petstore/templates/classpath.jelly. Para mi,
> Jelly no un language, es otro frankensteinXML ;-) pero entiendo bastante
> para genera el .wtpmodules
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]

-- 
Buenos Aires, Argentina 22°C with winds at 22 km/h NNE


pgpJfjeiJrvPQ.pgp
Description: PGP signature


[jira] Created: (MPJETTY-8) missing classpath entries during dinamic compilation

2005-10-09 Thread Juan F. Codagnone (JIRA)
missing classpath entries during dinamic compilation


 Key: MPJETTY-8
 URL: http://jira.codehaus.org/browse/MPJETTY-8
 Project: maven-jetty-plugin
Type: Bug
 Reporter: Juan F. Codagnone



if the jsp uses the a  class defined in the war, it will fail the compilation. 
Ej:
  <%test.URIDirectory helper_uri = 
(test.URIDirectory)request.getAttribute("helper_uri"); %>

Can be "solved" with:
Index: plugin.jelly
===
--- plugin.jelly(revision 312511)
+++ plugin.jelly(working copy)
@@ -111,6 +111,8 @@
 
 
 
+
+
   
 


But it should better to add a goal jetty:jetty-init where the class would be 
defined. With this classpath defined the user can add his owns dependencies 
using a postGoal.


-- 
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
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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



[jira] Updated: (MNG-1150) be able to configure custom wagon's properties

2005-10-09 Thread Juan F. Codagnone (JIRA)
 [ http://jira.codehaus.org/browse/MNG-1150?page=all ]

Juan F. Codagnone updated MNG-1150:
---

Attachment: MNG-1150.diff

I played a bit with this, adding a  tag to settings.xml but i 
didn't found a way to configure complex properties with plexus (types != int, 
long, String,...). Maybe the patch save you some minutes.

Juan.


> be able to configure custom wagon's properties
> --
>
>  Key: MNG-1150
>  URL: http://jira.codehaus.org/browse/MNG-1150
>  Project: Maven 2
> Type: Improvement
> Reporter: Juan F. Codagnone
>  Fix For: 2.0-beta-4
>  Attachments: MNG-1150.diff
>
>
> It should be allowed to configure the custom settings of each wagon provider. 
> This would give lot of flexiblity to the user to adapt the wagon provider to 
> his environment. 
> For example, in wagon-ssh i would like to configure WAGONSSH-12 settings or 
> in a https wagon i would things related with CA keys and trust.

-- 
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
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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



[jira] Created: (MNG-1150) be able to configure custom wagon's properties

2005-10-09 Thread Juan F. Codagnone (JIRA)
be able to configure custom wagon's properties
--

 Key: MNG-1150
 URL: http://jira.codehaus.org/browse/MNG-1150
 Project: Maven 2
Type: Improvement
 Reporter: Juan F. Codagnone



It should be allowed to configure the custom settings of each wagon provider. 
This would give lot of flexiblity to the user to adapt the wagon provider to 
his environment. 

For example, in wagon-ssh i would like to configure WAGONSSH-12 settings or in 
a https wagon i would things related with CA keys and trust.




-- 
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
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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



[jira] Commented: (WAGONSSH-2) wagon-ssh unit tests fail

2005-09-20 Thread Juan F. Codagnone (JIRA)
[ http://jira.codehaus.org/browse/WAGONSSH-2?page=comments#action_46757 ] 

Juan F. Codagnone commented on WAGONSSH-2:
--

 WAGONSSH-7 was a dup of this. sorry about that!

> wagon-ssh unit tests fail
> -
>
>  Key: WAGONSSH-2
>  URL: http://jira.codehaus.org/browse/WAGONSSH-2
>  Project: wagon-ssh
> Type: Bug
> Reporter: Brett Porter
> Assignee: Michal Maczka
>  Fix For: 1.0-alpha-5

>
>
> both tests error out with some sort of auth error

-- 
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
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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



[jira] Commented: (WAGONSSH-11) sftp: implement method getIfNewer()

2005-09-11 Thread Juan F. Codagnone (JIRA)
[ http://jira.codehaus.org/browse/WAGONSSH-11?page=comments#action_46146 ] 

Juan F. Codagnone commented on WAGONSSH-11:
---

@see MAVEN-1686 

> sftp: implement method getIfNewer()
> ---
>
>  Key: WAGONSSH-11
>  URL: http://jira.codehaus.org/browse/WAGONSSH-11
>  Project: wagon-ssh
> Type: Improvement
> Reporter: Juan F. Codagnone
>  Attachments: WAGON-SSH-11.diff
>
>
> implement Wagon::getIfNewer to let the wagon-ssh can be used from maven-1.
> (i will file the maven-1issue later)

-- 
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
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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



[jira] Updated: (MAVEN-1686) be able to use sftp as a maven.repo.remote

2005-09-11 Thread Juan F. Codagnone (JIRA)
 [ http://jira.codehaus.org/browse/MAVEN-1686?page=all ]

Juan F. Codagnone updated MAVEN-1686:
-

Attachment: MAVEN-1686.diff

As a quick hack, this patch makes sftp work. Its limitation is that the 
username and password must be hardcoded in the url. 
Depends on WAGONSSH-11 . Instead of adding another if, i have created a 
WagonFactory.

Example:

$ cat project.properties
maven.repo.remote=sftp://${mytest.user}:[EMAIL PROTECTED]/tmp/ble

$ cat build.properties
mytest.user=test
mytest.password=test


> be able to use sftp as a maven.repo.remote
> --
>
>  Key: MAVEN-1686
>  URL: http://jira.codehaus.org/browse/MAVEN-1686
>  Project: Maven
> Type: Wish
>   Components: core
> Reporter: Juan F. Codagnone
>  Attachments: MAVEN-1686.diff
>
>
> It would be nice to be able to use sftp remote private repositories, as they 
> are easier to admin than https, with custom CA.

-- 
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
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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



[jira] Created: (MAVEN-1686) be able to use sftp as a maven.repo.remote

2005-09-11 Thread Juan F. Codagnone (JIRA)
be able to use sftp as a maven.repo.remote
--

 Key: MAVEN-1686
 URL: http://jira.codehaus.org/browse/MAVEN-1686
 Project: Maven
Type: Wish
  Components: core  
 Reporter: Juan F. Codagnone



It would be nice to be able to use sftp remote private repositories, as they 
are easier to admin than https, with custom CA.



-- 
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
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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



[jira] Created: (MNG-834) handle repository permissions

2005-09-04 Thread Juan F. Codagnone (JIRA)
handle repository permissions
-

 Key: MNG-834
 URL: http://jira.codehaus.org/browse/MNG-834
 Project: Maven 2
Type: Improvement
  Components: maven-model, maven-archiver  
 Reporter: Juan F. Codagnone



it would be nice to have a way to set the directory/file permission and group 
to the remote repositories.
the wagon api already supports those permisions and the implementation almost 
handle them ( WAGONSSH-8 WAGONSSH-9).

A way to declare this permissions is missing . I was thinking to change the pom 
schma to allow something like:

   ssh-test
   a test for wagon-ssh
   sftp://localhost/tmp/m2/
   default
   
  770
  770
  users
   


but it can be also set it up in the plugin configuration.

I am willing to code it (i want the feature to be able to set up a private 
repository over ssh), but i need a senior decision for the way to configure it.

Juan.

-- 
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
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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



[jira] Created: (WAGONSSH-9) patch: sftp: honour repository directory permission mode

2005-09-03 Thread Juan F. Codagnone (JIRA)
patch: sftp: honour repository directory permission mode


 Key: WAGONSSH-9
 URL: http://jira.codehaus.org/browse/WAGONSSH-9
 Project: wagon-ssh
Type: Improvement
 Reporter: Juan F. Codagnone
 Attachments: sftp-honour-mode.diff

makes the Sftp wagon to honor the directory mode. pretty safe

M2 pom model doesn't support permission definition (¿yet?) so to test you need 
to inject some permisions when the Repository is created (i did it at [EMAIL 
PROTECTED] 142)

-- 
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
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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



[jira] Created: (WAGONSSH-8) patch: scp: honour repository directory permission mode

2005-09-03 Thread Juan F. Codagnone (JIRA)
patch: scp: honour repository directory permission mode
---

 Key: WAGONSSH-8
 URL: http://jira.codehaus.org/browse/WAGONSSH-8
 Project: wagon-ssh
Type: Improvement
 Reporter: Juan F. Codagnone
 Attachments: scp-honour-mode.diff

makes the Scp wagon to honor the directory mode. follow (posix?) mkdir 
conventions ("By default, the mode of created directories is 0777 (`a+rwx') 
minus the bits set in the umask").

It remains the question whether  the directory mode  string should be shell 
escaped or if it was already validated before, or we trust the user (the best 
option!)

M2 pom model doesn't support permission definition (¿yet?) so to test you need 
to inject some permisions when the Repository is created (i did it at [EMAIL 
PROTECTED] 142)


-- 
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
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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



Re: [jira] Commented: (MPXDOC-154) system locale setting makes test cases fail.

2005-09-02 Thread Juan F. Codagnone

On Thursday 01 September 2005 21:25, Lukas Theussl wrote:
...
> Can you guys confirm that this still works for you?

yeap, that fixes the problem. The other solution that works, is telling the 
compiler that these java classes are written en latin1:

Index: project.properties
===
--- project.properties  (revision 266297)
+++ project.properties  (working copy)
@@ -18,3 +18,4 @@
 # P R O J E C T  P R O P E R T I E S
 # ---
 maven.junit.fork=yes
+maven.compile.encoding=ISO-8859-1


Regards,
 Juan.

pd. first post!

-- 
Buenos Aires, Argentina  8°C with winds at 24 km/h SSW


pgpzSLSh98YUD.pgp
Description: PGP signature


[jira] Commented: (MPJETTY-2) Cannot compile jsp pages

2005-06-23 Thread Juan F. Codagnone (JIRA)
[ http://jira.codehaus.org/browse/MPJETTY-2?page=comments#action_41920 ] 

Juan F. Codagnone commented on MPJETTY-2:
-

i just reach to the same solution. Others plugins uses ${tools.jar}

[EMAIL PROTECTED] jetty $ find ~/.maven/cache/|xargs grep tools.jar
/home/juan/.maven/cache/maven-dotuml-plugin-1.0/plugin.jelly:  

/home/juan/.maven/cache/maven-dotuml-plugin-1.0-java5-zauber/plugin.jelly:  

/home/juan/.maven/cache/maven-jellydoc-plugin-1.3.1/project.properties:maven.jar.javadoc=${tools.jar}


> Cannot compile jsp pages
> 
>
>  Key: MPJETTY-2
>  URL: http://jira.codehaus.org/browse/MPJETTY-2
>  Project: maven-jetty-plugin
> Type: Bug
> Versions: 1.1
> Reporter: Janne Kario
>  Attachments: jetty-jspcompilation.patch, maven-jetty-plugin-1.2-SNAPSHOT.jar
>
>
> tools.jar missing from plugin classpath -> cannot compile jsp pages

-- 
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
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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



[jira] Commented: (MAVEN-456) unable to access remote repository via https

2005-06-12 Thread Juan F. Codagnone (JIRA)
[ http://jira.codehaus.org/browse/MAVEN-456?page=comments#action_41101 ] 

Juan F. Codagnone commented on MAVEN-456:
-

before the regrets begins, let me warn  not to use the above script in 
computers shared between multiple users, because they can get the key 
passphrase.


> unable to access remote repository via https
> 
>
>  Key: MAVEN-456
>  URL: http://jira.codehaus.org/browse/MAVEN-456
>  Project: maven
> Type: Improvement
>   Components: core
> Versions: 1.0-beta-10
> Reporter: Christoph Gruenwald
>  Fix For: 1.1-beta-2

>
>
> the remote repository is only accessable through http; it is not possible to 
> access it via https.
> i needed to modify two methods in the class httputils to get this running 
> (see below).
> 
> public static void getFile( String url,
> File destinationFile,
> boolean ignoreErrors,
> boolean useTimestamp,
> String proxyHost,
> String proxyPort,
> String proxyUserName,
> String proxyPassword )
> throws Exception
> {
> String[] s = parseUrl( url );
> 
> // *** MODIFIED - BEGIN ***
> 
> // need to create url with separated parameters
> String protocol = s[0];
> String username = s[1];
> String password = s[2];
> String hostname = s[3];
> String hostport = s[4];
> String parsedUrl = s[5];
> 
> /*
> String username = s[0];
> String password = s[1];
> String parsedUrl = s[2];
> 
> URL source = new URL( parsedUrl );
> */
> 
> URL source = new URL(protocol, hostname, Integer.parseInt(hostport), 
> parsedUrl);
> 
> // *** MODIFIED - END *** 
> //set the timestamp to the file date.
> long timestamp = 0;
> boolean hasTimestamp = false;
> if ( useTimestamp && destinationFile.exists() )
> {
> timestamp = destinationFile.lastModified();
> hasTimestamp = true;
> }
> //set proxy connection
> useProxyUser( proxyHost, proxyPort, proxyUserName, proxyPassword );
> //set up the URL connection
> URLConnection connection = source.openConnection();
> 
> // *** MODIFIED - BEGIN ***
> 
> // need to set javax.net.ssl.HostnameVerifier for 
> javax.net.ssl.HttpsURLConnection, otherwise connection will be 
> refused
> if (connection instanceof javax.net.ssl.HttpsURLConnection) {
> ( (javax.net.ssl.HttpsURLConnection) connection).setHostnameVerifier(
> new javax.net.ssl.HostnameVerifier() {
> public boolean verify(String hostname, 
> javax.net.ssl.SSLSession session) {
> return true;
> }
> }
> );
> }
> 
> // *** MODIFIED - END ***
> 
> //modify the headers
> //NB: things like user authentication could go in here too.
> if ( useTimestamp && hasTimestamp )
> {
> connection.setIfModifiedSince( timestamp );
> }
> // prepare Java 1.1 style credentials
> if ( username != null || password != null )
> {
> String up = username + ":" + password;
> String encoding = null;
> // check to see if sun's Base64 encoder is available.
> try
> {
> sun.misc.BASE64Encoder encoder =
> (sun.misc.BASE64Encoder) Class.forName(
> "sun.misc.BASE64Encoder" ).newInstance();
> encoding = encoder.encode( up.getBytes() );
> }
> catch ( Exception ex )
> {
> // Do nothing, as for MavenSession we will never use
> // auth and we will eventually move over httpclient
> // in the commons.
> }
> connection.setRequestProperty( "Authorization", "Basic " + encoding );
> }
> ...
> }
> 
> static String[] parseUrl( String url )
> {
> // *** MODIFIED - BEGIN ***
> 
> // parsed url into more paramters - it must be created with separated 
> parameters
> // this also fixes a bug caused in 
> org.apache.maven.verifier.DependencyVerifier#getRemoteArtifact(Artifact)
>  when a https-url is used
> 
> /*
> String[] parsedUrl = new String[3];
> parsedUrl[0] = null;
> parsedUrl[1] = null;
>   

[jira] Commented: (MAVEN-456) unable to access remote repository via https

2005-06-11 Thread Juan F. Codagnone (JIRA)
 [ http://jira.codehaus.org/browse/MAVEN-456?page=comments#action_41075 ]
 
Juan F. Codagnone commented on MAVEN-456:
-

with maven-1.0.2 I was able to use a private remote repository (using ssl, and 
a client certificate to restrict access).

To make it work, I had to set some system properties. That is a bad thing 
because its a hell if you have to differents ssl repositories.  I setuped the 
system properties in ~/.mavenrc:

---8<--- ~/.mavenrc ---
REMOTE_REPO_CERTS=`pwd`/common/maven/bare/remote_repo/
export MAVEN_OPTS="$MAVEN_OPTS 
-Djavax.net.ssl.trustStore=$REMOTE_REPO_CERTS/ca.keystore 
-Djavax.net.ssl.keyStore=$REMOTE_REPO_CERTS/clientkey.p12-Djavax.net.ssl.keyStorePassword=superSecretPassphrase"
---

I didn't found any way to achieve the same results from a build.properties. 
Should't be possible?



> unable to access remote repository via https
> 
>
>  Key: MAVEN-456
>  URL: http://jira.codehaus.org/browse/MAVEN-456
>  Project: maven
> Type: Improvement
>   Components: core
> Versions: 1.0-beta-10
> Reporter: Christoph Gruenwald
>  Fix For: 1.1-beta-2

>
>
> the remote repository is only accessable through http; it is not possible to 
> access it via https.
> i needed to modify two methods in the class httputils to get this running 
> (see below).
> 
> public static void getFile( String url,
> File destinationFile,
> boolean ignoreErrors,
> boolean useTimestamp,
> String proxyHost,
> String proxyPort,
> String proxyUserName,
> String proxyPassword )
> throws Exception
> {
> String[] s = parseUrl( url );
> 
> // *** MODIFIED - BEGIN ***
> 
> // need to create url with separated parameters
> String protocol = s[0];
> String username = s[1];
> String password = s[2];
> String hostname = s[3];
> String hostport = s[4];
> String parsedUrl = s[5];
> 
> /*
> String username = s[0];
> String password = s[1];
> String parsedUrl = s[2];
> 
> URL source = new URL( parsedUrl );
> */
> 
> URL source = new URL(protocol, hostname, Integer.parseInt(hostport), 
> parsedUrl);
> 
> // *** MODIFIED - END *** 
> //set the timestamp to the file date.
> long timestamp = 0;
> boolean hasTimestamp = false;
> if ( useTimestamp && destinationFile.exists() )
> {
> timestamp = destinationFile.lastModified();
> hasTimestamp = true;
> }
> //set proxy connection
> useProxyUser( proxyHost, proxyPort, proxyUserName, proxyPassword );
> //set up the URL connection
> URLConnection connection = source.openConnection();
> 
> // *** MODIFIED - BEGIN ***
> 
> // need to set javax.net.ssl.HostnameVerifier for 
> javax.net.ssl.HttpsURLConnection, otherwise connection will be 
> refused
> if (connection instanceof javax.net.ssl.HttpsURLConnection) {
> ( (javax.net.ssl.HttpsURLConnection) connection).setHostnameVerifier(
> new javax.net.ssl.HostnameVerifier() {
> public boolean verify(String hostname, 
> javax.net.ssl.SSLSession session) {
> return true;
> }
> }
> );
> }
> 
> // *** MODIFIED - END ***
> 
> //modify the headers
> //NB: things like user authentication could go in here too.
> if ( useTimestamp && hasTimestamp )
> {
> connection.setIfModifiedSince( timestamp );
> }
> // prepare Java 1.1 style credentials
> if ( username != null || password != null )
> {
> String up = username + ":" + password;
> String encoding = null;
> // check to see if sun's Base64 encoder is available.
> try
> {
> sun.misc.BASE64Encoder encoder =
> (sun.misc.BASE64Encoder) Class.forName(
> "sun.misc.BASE64Encoder" ).newInstance();
> encoding = encoder.encode( up.getBytes() );
> }
> catch ( Exception ex )
> {
> // Do nothing, as for MavenSession we will never use
> // auth and we will eventually move over httpclient
> // in the commons.
> }
> connection.setRequestProperty( &