Move führt zum Verlust der Topic-History

12 March 2005 - 21:23 | Version 6 |

Problem

Wenn man ein Topci verschiebt, so wird die Revision auf 1 zurückgesetzt, da das RCS-File am neuen Ort nicht ins RCS-Directory verschoben wird.

Fehlersuche

  • /bin/rename : TWiki::UI::Manage::rename( $web, $topic, $userName, $query );
    • /lib/TWiki/UI/Manage : &TWiki::Store::renameTopic( $oldWeb, $oldTopic, $newWeb, $newTopic, "relink" );
      • /lib/TWiki/Store.pm:
        • my $topicHandler = _getTopicHandler( $oldWeb, $oldTopic, "" );
        • my $error = $topicHandler→moveMe( $newWeb, $newTopic );
          • /lib/TWiki/Store/RcsFile.pm
            • $self→_moveTopic( $newWeb, $newTopic );
   # Change data file
   my $new = TWiki::Store::RcsFile->new( $newWeb, $newTopic, "",
        ( pubDir =>$self->{pubDir}, dataDir => $self->{dataDir} ) );
   my $from = $self->{file};
   my $to =  $new->{file};
   if( ! move( $from, $to ) ) {
       $error .= "data file move failed.  ";

   # Change data file history
   my $oldHistory = $self->{rcsFile};
   if( ! $error && -e $oldHistory ) {
       if( ! move(
         $oldHistory,
         $new->{rcsFile}
       ) ) {
          $error .= "history file move failed.  ";
       }

Lösungsversuche


In lib/TWiki/Store/RcsFile.pm:

            #if( $self->useRcsDir() && -d "$dataDir/$web/RCS" ) {
            if( $self->{"useRcsDir"} && -d "$dataDir/$web/RCS" ) {

Das wars nicht ;-(
Umschalten auf RCSLite
Das wars nicht ;-(

Fix (Lösung wäre übertreiben)

In lib/TWiki/Store/RcsFile.pm in der Prozedur sub _makeFileName:
            #if( $self->useRcsDir() && -d "$dataDir/$web/RCS" ) {
               $extra = "/RCS";
            #}
This site is powered by FoswikiCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding wiki.doebe.li? Send feedback
This page was cached on 27 May 2025 - 06:10.