[Oar-commits] r2699 - in trunk/www/v3: . plugin src

auguste at users.gforge.inria.fr auguste at users.gforge.inria.fr
Sat Mar 6 21:44:08 CET 2010


Author: auguste
Date: 2010-03-06 21:44:08 +0100 (Sat, 06 Mar 2010)
New Revision: 2699

Modified:
   trunk/www/v3/Makefile
   trunk/www/v3/plugin/rst_converter.rb
   trunk/www/v3/src/default.template
   trunk/www/v3/src/default_with_news.template
   trunk/www/v3/src/index.page
Log:
webgen's plugin system is ugly...

Modified: trunk/www/v3/Makefile
===================================================================
--- trunk/www/v3/Makefile	2010-03-05 09:12:46 UTC (rev 2698)
+++ trunk/www/v3/Makefile	2010-03-06 20:44:08 UTC (rev 2699)
@@ -24,6 +24,7 @@
 	cd output/users; ln -s ../images; cd -
 	
 upload: all
+	scp -r output/* $(SITE)
 	scp -r ../../Docs/schemas $(SITE) #must be enhanced rsync png svg
 	scp -r output/* $(SITE)
 	touch upload

Modified: trunk/www/v3/plugin/rst_converter.rb
===================================================================
--- trunk/www/v3/plugin/rst_converter.rb	2010-03-05 09:12:46 UTC (rev 2698)
+++ trunk/www/v3/plugin/rst_converter.rb	2010-03-06 20:44:08 UTC (rev 2699)
@@ -6,13 +6,16 @@
 		:author => "Olivier Richard"
 		)
 
-	param 'rstfile', nil, 'The rst file to converte'
+	param 'rstfile', nil, 'The rst file to convert'
 	param 'path', '.', 'The path to rst file'
 	set_mandatory 'rstfile', true
 	register_tag 'rstconverter'
 
+  @@rst_files_already_processed = {} 
+
 	def process_tag(tag, chain)
 
+puts tag
 		rstfile = param('rstfile').split(',')
 
 		files = ""
@@ -20,14 +23,25 @@
 			files = files + " " + param('path') + '/' + filename
 		end
 
+    if !(@@rst_files_already_processed.key?(files)) then 
+#if true then
+
 #		if  File.exist?( param('path') + '/' + rstfile[0] )
 #			content = `cd rst_files ; ls `
+      puts "rstconvert files:  #{files}"
 			content = `cd rst_files ; cat #{files} | rst2html | egrep -v '^<\/body>|^<body>|^<!DOCTYPE|^<html xmlns|^<head>|^<\/head>|^<meta|^<title>|^<link|^</\html>'`
 #		else
 #		  log(:error) { "#{param('path') + '/' + rstfile[0]}  file doesn't exist"}
 #			content = ''
 #		end
-
+      @@rst_files_already_processed[files] = content
+    else
+      puts "already processed: #{files}"
+      #content = @@rst_files_already_processed[files]
+      @@rst_files_already_processed.delete(files)
+  #   puts content
+      content= ""
+    end
 		return content
 	end
 end

Modified: trunk/www/v3/src/default.template
===================================================================
--- trunk/www/v3/src/default.template	2010-03-05 09:12:46 UTC (rev 2698)
+++ trunk/www/v3/src/default.template	2010-03-06 20:44:08 UTC (rev 2699)
@@ -45,7 +45,7 @@
       	<div id="copyright">
            <span style="float: left; padding-left: 20px;">
            	 <span id='copy' title='Copyright notice'>
-    					 <p>&copy; 2008 OAR Team
+    					 <p>&copy; 2010 OAR Team
 						 </span>
            </span>
            <span style="float: right; display: block; padding-right: 20px;">

Modified: trunk/www/v3/src/default_with_news.template
===================================================================
--- trunk/www/v3/src/default_with_news.template	2010-03-05 09:12:46 UTC (rev 2698)
+++ trunk/www/v3/src/default_with_news.template	2010-03-06 20:44:08 UTC (rev 2699)
@@ -57,7 +57,7 @@
       	<div id="copyright">
            <span style="float: left; padding-left: 20px;">
            	 <span id='copy' title='Copyright notice'>
-    					 <p>&copy; 2008 OAR Team
+    					 <p>&copy; 2010 OAR Team
 						 </span>
            </span>
            <span style="float: right; display: block; padding-right: 20px;">

Modified: trunk/www/v3/src/index.page
===================================================================
--- trunk/www/v3/src/index.page	2010-03-05 09:12:46 UTC (rev 2698)
+++ trunk/www/v3/src/index.page	2010-03-06 20:44:08 UTC (rev 2699)
@@ -5,8 +5,9 @@
 template: default_with_news.template
 ---
 
-h4. OAR is a resource manager (or batch scheduler) for large clusters.
+h4. OAR is a versatile resource manager (or batch scheduler) for large clusters.
 
+
 h2. Forge link
 
 All the development effort is stored in the INRIA gforge service : "https://gforge.inria.fr/projects/oar/":https://gforge.inria.fr/projects/oar/.
@@ -18,5 +19,4 @@
     * mailing lists
     * source repository
 
-
 <notextile>{rstconverter: {rstfile: doc_overview.rst}}<notextile>




More information about the Oar-commits mailing list