← Back to team overview

yade-dev team mailing list archive

[Branch ~yade-dev/yade/trunk] Rev 2673: 1. jquery.js in documentation is now symlink to a packaged jquery, if it is available.

 

------------------------------------------------------------
revno: 2673
committer: Anton Gladky <gladky.anton@xxxxxxxxx>
branch nick: yade
timestamp: Mon 2011-01-24 00:12:43 +0100
message:
  1. jquery.js in documentation is now symlink to a packaged jquery, if it is available.
modified:
  doc/sphinx/yadeSphinx.py


--
lp:yade
https://code.launchpad.net/~yade-dev/yade/trunk

Your team Yade developers is subscribed to branch lp:yade.
To unsubscribe from this branch go to https://code.launchpad.net/~yade-dev/yade/trunk/+edit-subscription
=== modified file 'doc/sphinx/yadeSphinx.py'
--- doc/sphinx/yadeSphinx.py	2011-01-09 16:34:50 +0000
+++ doc/sphinx/yadeSphinx.py	2011-01-23 23:12:43 +0000
@@ -178,7 +178,7 @@
 			out.append(m.group(1)+bbb+m.group(3)+'\n')
 		changed=True
 	if changed:
-		shutil.move(f,f+'~')
+		shutil.move(f,f+'_')
 		ff=open(f,'w')
 		for l in out:
 			ff.write(l)
@@ -217,5 +217,8 @@
 	sys.argv=['sphinx-build','-a','-E','-b','%s'%writer,'-d',outDir+'/doctrees','.',outDir+'/%s'%writer]
 	sphinx.main(sys.argv)
 	makeBaseClassesClickable((outDir+'/html/yade.wrapper.html' if writer=='html' else outDir+'/latex/Yade.tex'),writer)
+	if (os.path.exists('/usr/share/javascript/jquery/jquery.js')): #Check, whether jquery.js installed in system
+		os.system('rm '+ outDir+'/html/_static/jquery.js')
+		os.system('ln -s /usr/share/javascript/jquery/jquery.js '+ outDir+'/html/_static/jquery.js')
 
 sys.exit()