You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by br...@apache.org on 2005/05/24 10:14:29 UTC

svn commit: r178137 - in /maven/maven-1/core/trunk/src: java/org/apache/maven/cli/App.java messages/messages.properties messages/messages_fr.properties

Author: brett
Date: Tue May 24 01:14:27 2005
New Revision: 178137

URL: http://svn.apache.org/viewcvs?rev=178137&view=rev
Log:
improve the appearance

Modified:
    maven/maven-1/core/trunk/src/java/org/apache/maven/cli/App.java
    maven/maven-1/core/trunk/src/messages/messages.properties
    maven/maven-1/core/trunk/src/messages/messages_fr.properties

Modified: maven/maven-1/core/trunk/src/java/org/apache/maven/cli/App.java
URL: http://svn.apache.org/viewcvs/maven/maven-1/core/trunk/src/java/org/apache/maven/cli/App.java?rev=178137&r1=178136&r2=178137&view=diff
==============================================================================
--- maven/maven-1/core/trunk/src/java/org/apache/maven/cli/App.java (original)
+++ maven/maven-1/core/trunk/src/java/org/apache/maven/cli/App.java Tue May 24 01:14:27 2005
@@ -605,15 +605,15 @@
         final long mb = 1024 * 1024;
         System.gc();
         Runtime r = Runtime.getRuntime();
-        log.debug( MavenUtils.getMessage( "build.final.memory" ) + ((r.totalMemory() - r.freeMemory()) / mb) + "M/" + (r.totalMemory() / mb) + "M");
+        log.debug( MavenUtils.getMessage( "build.final.memory", ((r.totalMemory() - r.freeMemory()) / mb) + "M/" + (r.totalMemory() / mb) + "M") );
 
         Date fullStop = new Date();
         DateFormat defaultDate = DateFormat.getDateTimeInstance(DateFormat.FULL, DateFormat.LONG);
 
         long fullDiff = fullStop.getTime() - fullStart.getTime();
 
-        log.info( MavenUtils.getMessage( "build.total.time" ) + formatTime( fullDiff ) );
-        log.info( MavenUtils.getMessage( "build.finished.time" ) + defaultDate.format( fullStop ) );
+        log.info( MavenUtils.getMessage( "build.total.time", formatTime( fullDiff ) ) );
+        log.info( MavenUtils.getMessage( "build.finished.time", defaultDate.format( fullStop ) ) );
 
         log.info( "" );
 

Modified: maven/maven-1/core/trunk/src/messages/messages.properties
URL: http://svn.apache.org/viewcvs/maven/maven-1/core/trunk/src/messages/messages.properties?rev=178137&r1=178136&r2=178137&view=diff
==============================================================================
--- maven/maven-1/core/trunk/src/messages/messages.properties (original)
+++ maven/maven-1/core/trunk/src/messages/messages.properties Tue May 24 01:14:27 2005
@@ -45,9 +45,9 @@
 build.jellyException.line=Line...... ${1}
 build.jellyException.column=Column.... ${1}
 build.internalError=INTERNAL ERROR
-build.final.memory=Final Memory :\u0020
-build.total.time=Total time :\u0020
-build.finished.time=Finished at :\u0020 
+build.final.memory=Final Memory : ${1}
+build.total.time=Total time   : ${1}
+build.finished.time=Finished at  : ${1}
 displayBugReportHelp.line1=You have encountered an unknown error running Maven. 
 displayBugReportHelp.line2=Please help us to correct this problem by following these simple steps:
 displayBugReportHelp.line3=- read the Maven FAQ at ${1}

Modified: maven/maven-1/core/trunk/src/messages/messages_fr.properties
URL: http://svn.apache.org/viewcvs/maven/maven-1/core/trunk/src/messages/messages_fr.properties?rev=178137&r1=178136&r2=178137&view=diff
==============================================================================
--- maven/maven-1/core/trunk/src/messages/messages_fr.properties (original)
+++ maven/maven-1/core/trunk/src/messages/messages_fr.properties Tue May 24 01:14:27 2005
@@ -44,9 +44,9 @@
 build.jellyException.line=Ligne..... ${1}
 build.jellyException.column=Colonne... ${1}
 build.internalError=ERREUR INTERNE
-build.final.memory=M\u00E9moire Finale :\u0020
-build.total.time=Temps total :\u0020
-build.finished.time=Fini le :\u0020
+build.final.memory=M\u00E9moire Finale : ${1}
+build.total.time=Temps total    : ${1}
+build.finished.time=Fini le        : ${1}
 displayBugReportHelp.line1=Vous avez rencontr\u00E9 une erreur inconnue en ex\u00E9cutant Maven.
 displayBugReportHelp.line2=Svp aidez-nous \u00E0 corriger ce probl\u00E8me en suivant ces \u00E9tapes :
 displayBugReportHelp.line3=- lisez la FAQ de Maven \u00E0 ${1}



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: i18n WAS: svn commit: r178137

Posted by Arnaud HERITIER <ah...@gmail.com>.
 
Hi


...
I tried that Brett said, without success. Here is a dummy bat file:

MODE CON[:] CP SELECT=yyy 
echo %yyy%

 
Brett wanted to say :
MODE CON CP SELECT=850
It is similar to chcp.
 
I don't like the idea to use MAVEN_OPTS because I'll forget it each time I use a different environment.
 
I think we can have a simple solution. We set the codepage in the batch with the same value for everyone.
MODE CON ...
java -Dfile.encoding..
But I'm not sure that it will work. We must test it.
 
The better solution is to find the cp and to use it but in windows if I tape :
C:\>MODE CON CP /STATUS
I reveive :
État du périphérique CON:
-------------------------
    Page de codes :   850
 
Or if I tape
C:\>chcp
I receive :
Page de codes active : 850
 
How can I extract the 850 (or other code)  in a DOS batch ??
 
Arnaud

RE: i18n WAS: svn commit: r178137

Posted by Vincent Siveton <vi...@gmail.com>.
Hi guys,

Arnaud summarized very well the "solutions" for the accent problem or other
special characters in a Windows prompt. 
For me, the best way is to get the current codepage in a batch (ie
maven.bat) and put it in the jvm. 
Personally, I am not hot about the idea to add -Dfile.encoding option in the
MAVEN_OPTS: we need to have a generic way. Thought?

I tried that Brett said, without success. Here is a dummy bat file:

MODE CON[:] CP SELECT=yyy
echo %yyy%

But I am not a DOS expert :)

About accents in the message_fr.properties, I saw that the translation of
FAILED is \u00c8CHOU\u00c8 ie ÉCHOUÉ. The É character is \u00c8 in java, so
correct:
http://www.fileformat.info/info/unicode/char/00c8/index.htm

I did this morning a new checkout and a new build. Working as expected.

Cheers,

Vincent


> -----Original Message-----
> From: Brett Porter [mailto:brett@apache.org]
> Sent: Wednesday, May 25, 2005 5:21 AM
> To: Maven Developers List
> Subject: Re: i18n WAS: svn commit: r178137
> 
> Arnaud HERITIER wrote:
> 
> >I found an old mail we have with Vincent.
> > There are 2 solutions to resolve this problem :
> > - Use the font "Lucida Console" and use the code page 1252 :
> >chcp 1252
> >(The default is 850 - in France)
> > - Give to the jvm the codepage to use : -Dfile.encoding=Cp850
> > The best solution could be to find the codepage used in the console and
> >pass it to the jvm.
> >But actually I don't find how to get the codepage in a windows batch.
> > I'll try to investigate. If anyone have an idea ....
> >
> >
> "help mode" shows:
> 
> Select code page:  MODE CON[:] CP SELECT=yyy
> 
> (still there from when I needed it in dos 3.3!)
> 
> or, you could put the encoding in MAVEN_OPTS
> 
> - Brett
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: i18n WAS: svn commit: r178137

Posted by Brett Porter <br...@apache.org>.
Arnaud HERITIER wrote:

>I found an old mail we have with Vincent.
> There are 2 solutions to resolve this problem :
> - Use the font "Lucida Console" and use the code page 1252 :
>chcp 1252
>(The default is 850 - in France)
> - Give to the jvm the codepage to use : -Dfile.encoding=Cp850
> The best solution could be to find the codepage used in the console and 
>pass it to the jvm.
>But actually I don't find how to get the codepage in a windows batch.
> I'll try to investigate. If anyone have an idea ....
>  
>
"help mode" shows:

Select code page:  MODE CON[:] CP SELECT=yyy

(still there from when I needed it in dos 3.3!)

or, you could put the encoding in MAVEN_OPTS

- Brett


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: i18n WAS: svn commit: r178137

Posted by Arnaud HERITIER <ah...@gmail.com>.
I found an old mail we have with Vincent.
 There are 2 solutions to resolve this problem :
 - Use the font "Lucida Console" and use the code page 1252 :
chcp 1252
(The default is 850 - in France)
 - Give to the jvm the codepage to use : -Dfile.encoding=Cp850
 The best solution could be to find the codepage used in the console and 
pass it to the jvm.
But actually I don't find how to get the codepage in a windows batch.
 I'll try to investigate. If anyone have an idea ....
 Arnaud


 On 5/25/05, Brett Porter <br...@apache.org> wrote: 
> 
> Isn't this just an incompatibility between what locale you have set and
> what your console supports? Or is this what ant:exec munges it into?
> 
> This patch also came from Vincent Siveton: Vincent, can you confirm it
> works as you expected after I applied it?
> 
> Thanks,
> Brett
> 
> Arnaud HERITIER wrote:
> 
> >Hi,
> >
> >I'm not sure if it is a good idea to use characters with accent :
> >
> >
> > [exec] LA CONSTRUCTION A ╚CHOU╚
> > [exec] Fichier... D:\Work\Dev\apache-maven-1.1\core\trunk\maven.xml
> > [exec] ╚lement... maven:maven
> >
> >I have some weird characters ...
> >
> >
> >
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
> 
>

i18n WAS: svn commit: r178137

Posted by Brett Porter <br...@apache.org>.
Isn't this just an incompatibility between what locale you have set and 
what your console supports? Or is this what ant:exec munges it into?

This patch also came from Vincent Siveton: Vincent, can you confirm it 
works as you expected after I applied it?

Thanks,
Brett

Arnaud HERITIER wrote:

>Hi,
>
>I'm not sure if it is a good idea to use characters with accent :
>
>
>     [exec] LA CONSTRUCTION A ╚CHOU╚
>     [exec] Fichier... D:\Work\Dev\apache-maven-1.1\core\trunk\maven.xml
>     [exec] ╚lement... maven:maven
>
>I have some weird characters ...
>
>  
>


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


RE: svn commit: r178137 - in /maven/maven-1/core/trunk/src: java/org/apache/maven/cli/App.java messages/messages.properties messages/messages_fr.properties

Posted by Arnaud HERITIER <ah...@gmail.com>.
Hi,

I'm not sure if it is a good idea to use characters with accent :


     [exec] LA CONSTRUCTION A ╚CHOU╚
     [exec] Fichier... D:\Work\Dev\apache-maven-1.1\core\trunk\maven.xml
     [exec] ╚lement... maven:maven

I have some weird characters ...

Arnaud

> -----Message d'origine-----
> De : brett@apache.org [mailto:brett@apache.org] 
> Envoyé : mardi 24 mai 2005 10:14
> À : cvs@maven.apache.org
> Objet : svn commit: r178137 - in 
> /maven/maven-1/core/trunk/src: 
> java/org/apache/maven/cli/App.java 
> messages/messages.properties messages/messages_fr.properties
> 
> Author: brett
> Date: Tue May 24 01:14:27 2005
> New Revision: 178137
> 
> URL: http://svn.apache.org/viewcvs?rev=178137&view=rev
> Log:
> improve the appearance
> 
> Modified:
>     maven/maven-1/core/trunk/src/java/org/apache/maven/cli/App.java
>     maven/maven-1/core/trunk/src/messages/messages.properties
>     maven/maven-1/core/trunk/src/messages/messages_fr.properties
> 
> Modified: 
> maven/maven-1/core/trunk/src/java/org/apache/maven/cli/App.java
> URL: 
> http://svn.apache.org/viewcvs/maven/maven-1/core/trunk/src/jav
> a/org/apache/maven/cli/App.java?rev=178137&r1=178136&r2=178137
> &view=diff
> ==============================================================
> ================
> --- 
> maven/maven-1/core/trunk/src/java/org/apache/maven/cli/App.jav
> a (original)
> +++ 
> maven/maven-1/core/trunk/src/java/org/apache/maven/cli/App.java Tue 
> +++ May 24 01:14:27 2005
> @@ -605,15 +605,15 @@
>          final long mb = 1024 * 1024;
>          System.gc();
>          Runtime r = Runtime.getRuntime();
> -        log.debug( MavenUtils.getMessage( 
> "build.final.memory" ) + ((r.totalMemory() - r.freeMemory()) 
> / mb) + "M/" + (r.totalMemory() / mb) + "M");
> +        log.debug( MavenUtils.getMessage( "build.final.memory", 
> + ((r.totalMemory() - r.freeMemory()) / mb) + "M/" + 
> (r.totalMemory() / 
> + mb) + "M") );
>  
>          Date fullStop = new Date();
>          DateFormat defaultDate = 
> DateFormat.getDateTimeInstance(DateFormat.FULL, DateFormat.LONG);
>  
>          long fullDiff = fullStop.getTime() - fullStart.getTime();
>  
> -        log.info( MavenUtils.getMessage( "build.total.time" 
> ) + formatTime( fullDiff ) );
> -        log.info( MavenUtils.getMessage( 
> "build.finished.time" ) + defaultDate.format( fullStop ) );
> +        log.info( MavenUtils.getMessage( "build.total.time", 
> formatTime( fullDiff ) ) );
> +        log.info( MavenUtils.getMessage( "build.finished.time", 
> + defaultDate.format( fullStop ) ) );
>  
>          log.info( "" );
>  
> 
> Modified: maven/maven-1/core/trunk/src/messages/messages.properties
> URL: 
> http://svn.apache.org/viewcvs/maven/maven-1/core/trunk/src/mes
> sages/messages.properties?rev=178137&r1=178136&r2=178137&view=diff
> ==============================================================
> ================
> --- maven/maven-1/core/trunk/src/messages/messages.properties 
> (original)
> +++ maven/maven-1/core/trunk/src/messages/messages.properties 
> Tue May 24 
> +++ 01:14:27 2005
> @@ -45,9 +45,9 @@
>  build.jellyException.line=Line...... ${1}  
> build.jellyException.column=Column.... ${1}  
> build.internalError=INTERNAL ERROR -build.final.memory=Final 
> Memory :\u0020 -build.total.time=Total time :\u0020 
> -build.finished.time=Finished at :\u0020 
> +build.final.memory=Final Memory : ${1}
> +build.total.time=Total time   : ${1}
> +build.finished.time=Finished at  : ${1}
>  displayBugReportHelp.line1=You have encountered an unknown 
> error running Maven. 
>  displayBugReportHelp.line2=Please help us to correct this 
> problem by following these simple steps:
>  displayBugReportHelp.line3=- read the Maven FAQ at ${1}
> 
> Modified: maven/maven-1/core/trunk/src/messages/messages_fr.properties
> URL: 
> http://svn.apache.org/viewcvs/maven/maven-1/core/trunk/src/mes
> sages/messages_fr.properties?rev=178137&r1=178136&r2=178137&view=diff
> ==============================================================
> ================
> --- 
> maven/maven-1/core/trunk/src/messages/messages_fr.properties 
> (original)
> +++ 
> maven/maven-1/core/trunk/src/messages/messages_fr.properties Tue May 
> +++ 24 01:14:27 2005
> @@ -44,9 +44,9 @@
>  build.jellyException.line=Ligne..... ${1}  
> build.jellyException.column=Colonne... ${1}  
> build.internalError=ERREUR INTERNE 
> -build.final.memory=M\u00E9moire Finale :\u0020 
> -build.total.time=Temps total :\u0020 
> -build.finished.time=Fini le :\u0020
> +build.final.memory=M\u00E9moire Finale : ${1}
> +build.total.time=Temps total    : ${1}
> +build.finished.time=Fini le        : ${1}
>  displayBugReportHelp.line1=Vous avez rencontr\u00E9 une 
> erreur inconnue en ex\u00E9cutant Maven.
>  displayBugReportHelp.line2=Svp aidez-nous \u00E0 corriger ce 
> probl\u00E8me en suivant ces \u00E9tapes :
>  displayBugReportHelp.line3=- lisez la FAQ de Maven \u00E0 ${1}
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org For 
> additional commands, e-mail: dev-help@maven.apache.org
> 




---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org