]> git.pld-linux.org Git - packages/dokuwiki-plugin-pagemove.git/commitdiff
- up to 0.10.0 (20100218) AC-branch auto/ac/dokuwiki-plugin-pagemove-0_10_0-1 auto/th/dokuwiki-plugin-pagemove-0_10_0-1
authorElan Ruusamäe <glen@pld-linux.org>
Tue, 23 Mar 2010 09:01:37 +0000 (09:01 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    dokuwiki-plugin-pagemove-redirectlinks.patch -> 1.2
    dokuwiki-plugin-pagemove-selflinks.patch -> 1.2
    dokuwiki-plugin-pagemove.spec -> 1.9

dokuwiki-plugin-pagemove-redirectlinks.patch
dokuwiki-plugin-pagemove-selflinks.patch
dokuwiki-plugin-pagemove.spec

index cfbca92bb4eef9effc85aa63f50229567b94a0e8..c3ab7d4b1f361950d92ca5e0d81646c1fc299b72 100644 (file)
@@ -1,11 +1,11 @@
---- pagemove/admin.php 2008-02-25 19:02:48.062065053 +0200
-+++ pagemove/admin.php 2008-02-25 19:01:41.271159305 +0200
-@@ -411,7 +411,8 @@
+--- pagemove/admin.php~        2010-03-22 15:40:57.000000000 +0200
++++ pagemove/admin.php 2010-03-22 15:42:35.999975148 +0200
+@@ -698,7 +698,8 @@
      function _pm_updatelinks(&$text, $links)
      {
        foreach( $links as $old => $new ) {
--        $text = preg_replace( '#\[\[' . $old . '((\]\])|[\|\#])#i', '[[' . $new . '\1', $text);
-+        $text = preg_replace( '#\[\[' . $old . '(\]\]|[\|\#])#i', '[[' . $new . '\1', $text);
+-        $text = preg_replace( '#\[\[:?' . $old . '((\]\])|[\|\#])#i', '[[' . $new . '\1', $text);
++        $text = preg_replace( '#\[\[:?' . $old . '(\]\]|[\|\#])#i', '[[' . $new . '\1', $text);
 +        $text = preg_replace( '#~~REDIRECT>' . $old . '(~~|[\|\#])#i', '~~REDIRECT>' . $new . '\1', $text);
        }
      }
      
        //get text
        $text = io_readfile($base.'/'.$file);
-@@ -589,7 +597,13 @@
+--- pagemove/admin.php~        2010-03-22 15:44:35.000000000 +0200
++++ pagemove/admin.php 2010-03-22 15:45:49.644880286 +0200
+@@ -770,7 +770,13 @@
        //match all links
        //FIXME may be incorrect because of code blocks
        //      CamelCase isn't supported, too
--      preg_match_all('#\[\[(.+?)\]\]#si',$text,$matches,PREG_SET_ORDER);
+-      preg_match_all('#{{(.[^>]+?)}}#si',$text,$matches,PREG_SET_ORDER);
 +      $matches = array();
-+      if (preg_match_all('#\[\[(.+?)\]\]#s',$text,$m,PREG_SET_ORDER)) {
++        if (preg_match_all('#{{(.[^>]+?)}}#si',$text,$matches,PREG_SET_ORDER)) {
 +        $matches = array_merge($matches, $m);
-+      }
++        }
 +      if (preg_match_all('#~~REDIRECT>(.+?)~~#s',$text,$m,PREG_SET_ORDER)) {
 +        $matches = array_merge($matches, $m);
 +      }
        foreach($matches as $match){
          //get ID from link and discard most non wikilinks
-         list($mid) = split('[\|#]',$match[1],2);
+         list($mid) = split('(\?|\|)',$match[1],2);
index 130fca2a0c5c2b3b0f867868d7ffa274baa7b0f7..abf34a44c59098d1109200e3949b7c1d2e294700 100644 (file)
@@ -1,15 +1,12 @@
---- pagemove/admin.php 2008-02-25 19:03:30.679918614 +0200
-+++ pagemove/admin.php 2008-02-25 22:29:07.427283018 +0200
-@@ -213,24 +213,36 @@
-           saveWikiText($opts['new_id'], $this->text,
-             sprintf($this->lang[$lang_key], $ID, $opts['new_id']));
--          //Delete the orginal file.
--          //saveWikiText($ID, '', $this->lang['pm_movedto'].$opts['new_id']);
-           if (@file_exists(wikiFN($opts['new_id']))) @unlink(wikiFN($ID));
--          //Loop through backlinks
-+          // replace our old id with new one as we already renamed the page but 
+--- pagemove/admin.php~        2010-03-22 15:48:44.000000000 +0200
++++ pagemove/admin.php 2010-03-22 15:52:23.529214700 +0200
+@@ -600,22 +600,36 @@
+           //saveWikiText($ID, '', $this->lang['pm_movedto'].$opts['new_id']);
+           //if (@file_exists(wikiFN($opts['new_id']))) @unlink(wikiFN($ID));
+           if (@file_exists(wikiFN($opts['new_id']))) saveWikiText($ID, '',$this->lang['pm_delete'] );
+-            
++
++          // replace our old id with new one as we already renamed the page but
 +          // there might be backlinks (links to self in this case).
 +          $opts['id'] = cleanID($opts['ns'].':'.$opts['name']);
 +          $selfmod = isset($backlinks[$opts['id']]);
 +            $backlinks[$opts['new_id']] = $backlinks[$opts['id']];
 +            unset($backlinks[$opts['id']]);
 +          }
-+
-+          // Loop through backlinks
+           
+           //Loop through backlinks
            foreach($backlinks as $backlink => $links){
 -            $this->_pm_updatebacklinks($backlink, $links, $opts, $brackets);
 +            $this->_pm_updatebacklinks($backlink, $links, $opts);
            }
+           
            //Move the old revisions
            $this->_pm_movemeta('olddir', '/^'.$opts['name'].'\.[0-9]{10}\.txt(\.gz)?$/', $opts);
  
--          //Set things up to display the new page.
 +          // remove cache. again if we ourselves were modified (due backlinks)
 +          if ($selfmod) {
 +            $cache = new cache_instructions($opts['new_id'], wikiFN($opts['new_id']));
 +            $cache->removeCache();
 +          }
 +
+           //Set things up to display the new page.
            io_saveFile($conf['cachedir'].'/purgefile',time());
 -          $ID = $opts['new_id'];
 -          $ACT = 'show';
        unlock($id);
      }
  
-@@ -627,4 +639,6 @@
-       }
-     }
--}
-\ No newline at end of file
-+}
-+
-+// vim:set ts=2 et sw=2
index a01522e1397fa0e8322f9ef8fa2fffa2d0a64107..448b2ef524aa3ed0e482b545a6a7b750166a61d1 100644 (file)
@@ -2,13 +2,12 @@
 Summary:       DokuWiki PageMove plugin
 Summary(pl.UTF-8):     Wtyczka PageMove dla DokuWiki
 Name:          dokuwiki-plugin-%{plugin}
-Version:       0.9.15a
+Version:       0.10.0
 Release:       1
 License:       GPL v2
 Group:         Applications/WWW
-# Source0Download:     http://www.isection.co.uk/lib/exe/fetch.php?media=pagemove_20070722.zip
-Source0:       pagemove_20070722.zip
-# Source0-md5: f2cc2a57d40b877a335b52009e4cc072
+Source0:       http://acodeas.de/plugins/Version%{version}-pagemove_20100218.zip
+# Source0-md5: 48d2d8dde2794a9a5af5344623d608e8
 Patch0:                %{name}-redirectlinks.patch
 Patch1:                %{name}-selflinks.patch
 URL:           http://www.isection.co.uk/doku.php
@@ -52,6 +51,9 @@ mv lang/cs/pagemove.txt{.txt,}
 mv lang/es/pagemove.txt{.txt,}
 mv lang/pl/pagemove.txt{.txt,}
 
+# cleanup backups after patching
+find '(' -name '*~' -o -name '*.orig' ')' -print0 | xargs -0 -r -l512 rm -f
+
 %install
 rm -rf $RPM_BUILD_ROOT
 install -d $RPM_BUILD_ROOT%{plugindir}
This page took 0.125869 seconds and 4 git commands to generate.