You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lenya.apache.org by Thorsten Scherler <th...@juntadeandalucia.es> on 2004/07/26 10:37:57 UTC

Patches for lenya

Hello devs,

Wolgang added this comment to Bug 30231:
"What commands / scripts should actually be used to apply a patch ? I will be
happy to test these commands on a fresh checkout to get everything working,
before creating a new patch. "

patch -d ...
http://list-archive.xemacs.org/xemacs-beta/199912/msg00591.html
http://cvsbook.red-bean.com/cvsbook.html


"Could someone post this "how to apply a patch in Lenya" information here, I will
test it and add it to the wiki if that's ok ? Also, any information on "how to
add a new file" would be helpful. I couldn't find anything on the Cocoon pages
about these issues."

You can use CLI. I am using eclipse and the team perspecetive is straight forward. There you will find "apply patch". Select the patch you want to apply and that's it :).

BTW, please, conduct discussions and question on the ml. The bugzilla is for patches, bug infos and todos. 

King regards
HTH
thorsten



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


Re: Patches for lenya

Posted by Wolfgang Kaltz <jw...@yahoo.com>.
Rolf Kulemann <roku <at> apache.org> writes:

> 
> Re the encoding problems:
> 
> You need to set your Eclipse encoding to UTF-8. Its somewhere in the
> Preferences.
> 
> Hope that helps.

Hi Rolf & thanks for the suggestion,
the encoding set in Eclipse does not seem to be relevant, however your comment
brought me on the right track. Despite of what the Admin GUI of my machine
(SuSE 9.0) tells me, my environment wasn't using UTF-8 encoding. When I set it
by hand and restart Eclipse, the diffs in the cmsui_de.xml are now matched :)

Conclusion: it seems that Eclipse (when the environment is ok) does generate 
patches which are appropriate for Lenya. I posted that patch to 
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=30231 

-> some more info I can add to the Wiki today ;)




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


Re: Patches for lenya

Posted by Rolf Kulemann <ro...@apache.org>.
On Tue, 2004-07-27 at 15:36, Wolfgang Kaltz wrote:
...
> My environment seems OK, Eclipse is showing me the Umlauts. However, when
> creating the patch, the diff file loses the umlauts. Consequently, when
> trying to apply the patch on another installation, Eclipse says it cannot match
> (although it does show the new lines !?). All other diffs match, so the 
> problem is very likely coming from the UTF-8 encoding in this file
> 
> Has anybody worked with diffs on a file coded in UTF-8, such as the 
> cmsui_de.xml ? I've tried in the command line and in Eclipse, I've also been
> searching on the Internet, but I just cannot find a way to get the cmsui_de 
> working in the patch :(

Re the encoding problems:

You need to set your Eclipse encoding to UTF-8. Its somewhere in the
Preferences.

Hope that helps.
-- 
Rolf Kulemann


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


Re: Patches for lenya

Posted by Thorsten Scherler <th...@juntadeandalucia.es>.
Wolfgang Kaltz wrote:

>Gregor J. Rothfuss <gregor <at> apache.org> writes:
>  
>
>My environment seems OK, Eclipse is showing me the Umlauts. However, when
>creating the patch, the diff file loses the umlauts. Consequently, when
>trying to apply the patch on another installation, Eclipse says it cannot match
>(although it does show the new lines !?). All other diffs match, so the 
>problem is very likely coming from the UTF-8 encoding in this file
>
>Has anybody worked with diffs on a file coded in UTF-8, such as the 
>cmsui_de.xml ? I've tried in the command line and in Eclipse, I've also been
>searching on the Internet, but I just cannot find a way to get the cmsui_de 
>working in the patch :(
>
>  
>
Hi Wolfgang,

one nice plugin for xml is http://www.xmlbuddy.com/.
If you installed that plugin go to
window-preference
XMLBuddy-XML-Encoding (select "default to utf-8")

After that open the cmsui_de.xml with the buddy. If you have opened the 
file with the buddy the menu point "xml" will appear . then just do:
XML-Format

By default that is the shortcut: crtl+shift+f

That will transform all Umlaute into &#...; syntax. Then you should be 
able to work with the patch.

HTH
thorsten


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


Re: Patches for lenya

Posted by Wolfgang Kaltz <jw...@yahoo.com>.
Gregor J. Rothfuss <gregor <at> apache.org> writes:

> Wolfgang Kaltz wrote:
> > Does somebody have another suggestion ?
> > 
> > (I could work around this by creating an inner class within an existing 
class -
> > in this case however this solution is not clean, as it would create 
> > dependencies in the code which do not need to be)
> 
> how does eclipse handle that? you can right click on a directory
> and create a patch

Hi Gregor
yes, I've been trying out Eclipse today for that purpose: it does handle new
files, and adds them to the diff file, it looks like this:

  RCS file: src/java/org/apache/lenya/ac/UserType.java
  diff -N src/java/org/apache/lenya/ac/UserType.java
  --- /dev/null   1 Jan 1970 00:00:00 -0000
  +++ src/java/org/apache/lenya/ac/UserType.java  1 Jan 1970 00:00:00 -0000
  @@ -0,0 +1,94 @@

I will post my patch as handled by Eclipse, hopefully it will be readable
by others ...
... however, I haven't done so yet because I have a problem with the character
sets in the cmsui_de.xml

My environment seems OK, Eclipse is showing me the Umlauts. However, when
creating the patch, the diff file loses the umlauts. Consequently, when
trying to apply the patch on another installation, Eclipse says it cannot match
(although it does show the new lines !?). All other diffs match, so the 
problem is very likely coming from the UTF-8 encoding in this file

Has anybody worked with diffs on a file coded in UTF-8, such as the 
cmsui_de.xml ? I've tried in the command line and in Eclipse, I've also been
searching on the Internet, but I just cannot find a way to get the cmsui_de 
working in the patch :(




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


Re: Patches for lenya

Posted by "Gregor J. Rothfuss" <gr...@apache.org>.
Wolfgang Kaltz wrote:

> Does somebody have another suggestion ?
> 
> (I could work around this by creating an inner class within an existing class -
> in this case however this solution is not clean, as it would create 
> dependencies in the code which do not need to be)

how does eclipse handle that? you can right click on a directory
and create a patch

-- 
Gregor J. Rothfuss
Wyona Inc.  -   Open Source Content Management   -   Apache Lenya
http://wyona.com                   http://cocoon.apache.org/lenya
gregor.rothfuss@wyona.com                       gregor@apache.org

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


Re: Patches for lenya

Posted by Wolfgang Kaltz <jw...@yahoo.com>.
Thorsten Scherler <thorsten.scherler.ext <at> juntadeandalucia.es> writes:

> "Could someone post this "how to apply a patch in Lenya" information here, I 
> will test it and add it to the wiki if that's ok ? Also, any information on 
> "how to add a new file" would be helpful. I couldn't find anything on the 
> Cocoon pages about these issues."
> 
> You can use CLI. I am using eclipse and the team perspecetive is straight
forward. There you will find "apply
> patch". Select the patch you want to apply and that's it :).
> 
> BTW, please, conduct discussions and question on the ml. The bugzilla is for
> patches, bug infos and todos. 

Hi all
I will try to keep track of patch help in the Wiki at
http://wiki.apache.org/cocoon-lenya/CodeContribution

There is however one tricky question remaining: what to do about a new file ?
I can't create a diff file for a file not yet in CVS. I found a posting on
the Internet about CVS Utilities from Cygnus, with which you can fool your 
local CVS to accept a new file, which you can then diff with diff -n
However, this format didn't work for Thorsten when he tried to apply the patch.

Does somebody have another suggestion ?

(I could work around this by creating an inner class within an existing class -
in this case however this solution is not clean, as it would create 
dependencies in the code which do not need to be)

Wolfgang



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