User Tools

Site Tools


web_page_editing

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
web_page_editing [2013/02/14 14:34]
bhkong Fixed svn checkout url
web_page_editing [2016/11/27 16:29] (current)
rdiazgar [Regenerate the static pages]
Line 1: Line 1:
-The vision group web page is hosted out of /​extra/​vision0 and managed with an SVN repository.   ​Don'​t make changes to the webpage directly, instead make them to a copy checked out from SVN.+The vision group webpage ​is managed with SVN repository, so changes ​should not be made to the webpage directly.
  
 +===== Checking out the repo =====
  
-The standard procedure is:+To get a copy of the repository, clone the ucivision webpage repository from bitbucket:
  
 +<​file>​
 +git clone git@bitbucket.org:​ucivision/​vision.ics.git
 +</​file>​
  
-1) Check out a copy from svn:+===== Updating content =====
  
 +Now that you have a copy of the repository, you should take a look at the README file located in “public_html/​scripts/​” to make sure your system has the prerequisite applications and libraries, before trying to make changes to the website. The webpage is semi-static in that the contents are served from static pages, but the pages themselves were dynamically generated by python scripts and xml files. Documented below are the most common changes you'd likely want to make to the webpage.
  
-<​file>​ +=== Adding People ===
- svn co https://​svn.ics.uci.edu/​titans/​visionweb/​ +
-</​file>​+
  
 +To add a person to the webpage, you'll need to do two things: (1) add a profile photo and (2) add an entry to the person database.
  
-2Add your papers in the appropriate format ​to the “public_html/​papers” directory+(1Before adding ​the photo, it should be cropped/​resized ​to 200×250 for optimal display and named using the convention: firstname_lastname.jpg. To add the photo, copy the file to “public_html/​images/​mugshots/​” (2) To add an entry to the person database, you'll want to edit peoplelist.xml located in “public_html/​scripts/​”. At the top of the file, you'll find a template that's commented out, which you can copy and add the new person with. The fields are hopefully self-explanatory,​ if not see other people entries as examples.
  
 +=== Adding Projects ===
  
-3) Run the python script ​to update ​the papers databaseautomatically generate thumbnails, etc.+To add a new project ​to the webpageyou'll want to edit projectlist.xml located in “public_html/​scripts/​”.
  
 +=== Adding Papers ===
  
-4) When you are satisfied that everything looks good, check your updates back in to svnRemember to svn add” any new files or directories you have added to the tree.+The naming convention for papers is to use the first author'​s last name appended with the first letter of the other authors (e.g., FowlkesMM for Fowlkes, Martin, and Malik) followed by the venue of publication and the publication year. All together it'll be like FowlkesMM_CVPR_2003”. Henceforth, we'll use “name” to denote this notation.
  
 +To add a new paper to the webpage, you'll want to create a directory inside “public_html/​papers/​” following the naming convention. Inside you'll add four files: abstract.html,​ icon.jpg, “name”.bibtex,​ and “name”.pdf.
  
-5) Finally, pull the updates from svn to the hosted directory.+abstract.html should contain only text or HTML code that is intended to go inside ​the <​body></​body>​ of a HTML file. icon.jpg is a small picture related ​to the paper“name”.bibtex is the bibtex file for the paper. “name”.pdf is the pdf of the paper. 
 +===== Regenerate the static pages =====
  
 +When you're done making changes, you can regenerate all static pages by running the following command:
  
 <​code>​ <​code>​
-gsu vision +python gen.py all
-cd /​extra/​vision0 +
-svn export https://svn.ics.uci.edu/​titans/​visionweb/​public_html/​ +
-find public_html/​ -type f -print -exec chmod a+r {} \; +
-find public_html/​ -type d -print -exec chmod a+rx {} \;+
 </​code>​ </​code>​
  
 +If you see errors when running the script, feel free to try to fix them yourself or bug Bailey.
  
-The final step will eventually be automated but for now just email Charless :)+Make sure your version of lxml and pybtex are up to date using the python pip tool. 
 + 
 +===== Commit your changes ===== 
 + 
 +When you are satisfied that everything looks good, commit your updates back in to git and push to the upstream origin. 
 + 
 +===== Updating the live site ===== 
 + 
 +The vision website is hosted on /​extra/​vision0 share which you can access on the titan cluster 
 + 
 +Note: the .html files make use of server side includes. ​ The department file server requires use of the "​XBitHack"​ which only processes server-side includes for files that are executable, hence the last "​find"​ operation above. 
 + 
 +This final step will eventually be automated but for now just email Charless :) 
 + 
 +---- 
 + 
 +New recipie 
 + 
 +<​code>​ 
 +gsu vision 
 +cd /​extra/​vision0/​vision.ics/​ 
 +git pull 
 +cd /​extra/​vision0/​ 
 +rsync -rv /​extra/​vision0/​vision.ics/​public_html/ ​ /​extra/​vision0/​public_html/​ 
 +find /​extra/​vision0/​public_html/​ -type f -print -exec chmod a+r {} \; 
 +find /​extra/​vision0/​public_html/​ -type d -print -exec chmod a+rx {} \; 
 +find /​extra/​vision0/​public_html/​ -type f -print -name "​*.html"​ -exec chmod a+rx {} \; 
 +chmod 644 /​extra/​vision0/​public_html/​.htaccess 
 +cd /​extra/​vision0/​vision.ics/​ 
 +</​code>​
  
web_page_editing.1360881240.txt.gz · Last modified: 2013/02/14 14:34 by bhkong