[WebSVN] Special chars

View: New views
3 Messages — Rating Filter:   Alert me  

[WebSVN] Special chars

by webpost :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,
(sorry for my english)

I use:
 - Centos 5.2
 - Websvn 2.2.1.
 - httpd-2.2.3-11

I run Httpd with the user apache.

My SVN users use special characters (like é ç à ô).

When they want to download an archive, they encountered 2 problems.

Structure of a repository:
toto
  |--> tata
  |--> tété
  |--> titi
  |--> tutu
totô
  |--> tata
  |--> titi
  |--> tutu

First problem:
If I want to download the "toto" folder. The "svn export" command stop after extract "tata" file.
Error message: "Unable to call svn command svn --config-dir /tmp ..."

To solve this problem, I set up the LANG var to "fr_FR.UTF-8" (instead of "C") for apache user.

I replace in command.php
line 115>> return @exec($cmd, $tmp, $retcode);)
by
line 115>> return @exec("export LANG=fr_FR.UTF-8; ".$cmd, $tmp, $retcode);

An other solution was to modify my php.ini or modify my apache user.

Second problem:
If I want to download the "totô" folder. The "svn export" works fine but I can't download file.
Error message: "Unable to open file ..."

If I look in "temp" folder, my archive was created but it calls tot.rXX.zip (instead of totô.rXX.zip).
The "quote" function strip special chars (escapeshellarg($str)) in "command.php" and you use this function in "exportDirectory" function (svnlook.php)

line 883>> $cmd = $config->svn.$this->repConfig->svnParams().quote($path.'@'.$rev).' '.quote($filename);
You export the content in temp/wsvnXXX/tot.rXX

To solve this problem, I add a new line in dl.php
line 154>>  $arcname = substr(quote($arcname), 1, -1);

Thanks to Websvn developpers.
My users are very satisfact to use this tools.

------------------------------------------------------
http://websvn.tigris.org/ds/viewMessage.do?dsForumId=1547&dsMessageId=2404049

To unsubscribe from this discussion, e-mail: [dev-unsubscribe@...].

RE: [WebSVN] Special chars

by Xavier CHOPIN :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Sorry for the presentation of the first post.

>>>>>>>>
Hi, (sorry for my english)

I use:
- Centos 5.2
- Websvn 2.2.1
- httpd-2.2.3-11

I run Httpd with the user apache.
My SVN users use special characters (like é ç à ô).

When they want to download an archive, they encountered 2 problems.

Structure of a repository:
toto
 |--> tata
 |--> tété
 |--> titi
 |--> tutu
totô
 |--> tata
 |--> titi
 |--> tutu

First problem:
If I want to download the "toto" folder. The "svn export" command stop after extract "tata" file.

Error message: "Unable to call svn command svn --config-dir /tmp ..."

To solve this problem, I set up the LANG var to "fr_FR.UTF-8" (instead of "C") for apache user.
I replace in command.php
line 115>> return @exec($cmd, $tmp, $retcode);)
by
line 115>> return @exec("export LANG=fr_FR.UTF-8; ".$cmd, $tmp, $retcode);

An other solution was to modify my php.ini or modify my apache user.

Second problem:
If I want to download the "totô" folder. The "svn export" works fine but I can't download file.

Error message: "Unable to open file ..."

If I look in "temp" folder, my archive was created but it calls tot.rXX.zip (instead of totô.rXX.zip).

The "quote" function strip special chars (escapeshellarg($str)) in "command.php" and you use this function in "exportDirectory" function (svnlook.php)
line 883>> $cmd = $config->svn.$this->repConfig->svnParams().quote($path.'@'.$rev).' '.quote($filename);

You export the content in temp/wsvnXX/tot.rXX

To solve this problem, I add a new line in dl.php
line 154>> $arcname = substr(quote($arcname), 1, -1);

Thanks to Websvn developpers. My users are very satisfact to use this tools.

------------------------------------------------------
http://websvn.tigris.org/ds/viewMessage.do?dsForumId=1547&dsMessageId=2404420

To unsubscribe from this discussion, e-mail: [dev-unsubscribe@...].

RE: [WebSVN] Special chars

by Xavier CHOPIN :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I have a problem with "Reply to message" interface.

See the attachments
Sorry for the presentation of the first post.


Hi, (sorry for my english)

I use:
- Centos 5.2
- Websvn 2.2.1.
- httpd-2.2.3-11

I run Httpd with the user apache. My SVN users use special characters (like é ç à ô).

When they want to download an archive, they encountered 2 problems.

Structure of a repository:
toto
 |--> tata
 |--> tété
 |--> titi
 |--> tutu
totô
 |--> tata
 |--> titi
 |--> tutu

First problem:
If I want to download the "toto" folder. The "svn export" command stop after extract "tata" file.

Error message: "Unable to call svn command svn --config-dir /tmp ..."

To solve this problem, I set up the LANG var to "fr_FR.UTF-8" (instead of "C") for apache user.
I replace in command.php
line 115>> return @exec($cmd, $tmp, $retcode);)
by
line 115>> return @exec("export LANG=fr_FR.UTF-8; ".$cmd, $tmp, $retcode);

An other solution was to modify my php.ini or modify my apache user.


Second problem:
If I want to download the "totô" folder. The "svn export" works fine but I can't download file.

Error message: "Unable to open file ..."

If I look in "temp" folder, my archive was created but it calls tot.rXX.zip (instead of totô.rXX.zip).
The "quote" function strip special chars (escapeshellarg($str)) in "command.php" and you use this function in "exportDirectory" function (svnlook.php)
line 883>> $cmd = $config->svn.$this->repConfig->svnParams().quote($path.'@'.$rev).' '.quote($filename);

You export the content in temp/wsvnXXX/tot.rXX

To solve this problem, I add a new line in dl.php
line 154>> $arcname = substr(quote($arcname), 1, -1);

Thanks to Websvn developpers. My users are very satisfact to use this tools.