[Koha-cvs] CVS: koha koha.upgrade,1.1.2.23,1.1.2.24

Steve Tonnesen tonnesen at users.sourceforge.net
Wed Oct 30 23:49:25 CET 2002


Update of /cvsroot/koha/koha
In directory usw-pr-cvs1:/tmp/cvs-serv12521

Modified Files:
      Tag: rel-1-2
	koha.upgrade 
Log Message:
Upgrade script preserves templates now.


Index: koha.upgrade
===================================================================
RCS file: /cvsroot/koha/koha/koha.upgrade,v
retrieving revision 1.1.2.23
retrieving revision 1.1.2.24
diff -C2 -r1.1.2.23 -r1.1.2.24
*** koha.upgrade	28 Oct 2002 22:59:46 -0000	1.1.2.23
--- koha.upgrade	30 Oct 2002 22:49:21 -0000	1.1.2.24
***************
*** 322,325 ****
--- 322,355 ----
  
  
+ # Copy custom templates and reports back in
+ 
+ opendir D, "$backupdir/kohafiles-$date/intranet/htdocs/";
+ my @dirlist=readdir D;
+ foreach (@dirlist) {
+     (next) if (/^\./);
+     (next) if ($_ eq 'default');
+     (next) if ($_ eq 'doc');
+     (next) if ($_=~/^koha-/);
+     (next) if (-e "$::intranetdir/htdocs/$_");
+     print "Restoring custom intranet templates $_...\n";
+     system("cp -a $backupdir/kohafiles-$date/intranet/htdocs/$_ $::intranetdir/htdocs/");
+ }
+ 
+ opendir D, "$backupdir/kohafiles-$date/opac/htdocs/";
+ my @dirlist=readdir D;
+ foreach (@dirlist) {
+     (next) if (/^\./);
+     (next) if ($_ eq 'default');
+     (next) if ($_ eq 'doc');
+     (next) if ($_=~/^koha-/);
+     (next) if (-e "$::opacdir/htdocs/$_");
+     print "Restoring custom opac template $_...\n";
+     system("cp -a $backupdir/kohafiles-$date/opac/htdocs/$_ $::opacdir/htdocs/");
+ }
+ 
+ 
+ 
+ 
+ 
  unless ($::kohalogdir && -e $::kohalogdir) {
      $::kohalogdir='/var/log/koha';





More information about the Koha-cvs mailing list