Changes

Jump to: navigation, search

OpenGrok

542 bytes added, 22:37, 12 November 2008
OpenGrok
== Introduction ==OpenGrok is a source code searcher similar in idea to MXR. It is very advanced and written in Java. It uses Apache Lucene to build a search database for a source code tree. This tool is perfect for the source browser new mercurial repository as it has built in hg repo parsing. There is only version number searching capability I think: you can't use my , for example, FIREFOX_3_1b1_RELEASE in the History box. If there is interest in Mozilla adopting this program, I'd be willing to write support for it. I'd also like to customize the look and feel for the OpenSolaris communityMozilla web sites. It uses Java Servlets running on Java5I have a list of things to do in my script.
== Features and Benefits ====== File History ==== [[OpenGrok maintains code version history. I am currently unsure of whether it looks at the CVS versioning information or whether it compares files between indexes. There is also options for many diffs and comparing different, non-concurrent versions.[http://cvs.opensolaris.org/source/history/on/usr/src/uts/sun/io/eri.c Examplescript|The Script]]
==== Extendable ==Setup==If there are files which cannot be analysed by Setting this up is fairly easy if you know your way around a unix shell. You will need the included analysersfollowing tools:* JDK 1.5+* Servlet container - JBoss, OpenGrok allows the user to develop their own analysersGlassfish, I am unsure of whether or not there is a JavaScript analyser allreadyTomcat, maybe even an XPCOM/XUL analyser could be writtenJetty, but I don't know the first thing about XPCOM/XUL so this maybe allready implemented in another languageetc. * Exuberant Ctags* Mercurial* Basic unix programs: sed, zip, unzip, nice, bash
==== In File Linking ====The indexer hyperlinks I am assuming you have set up all symbols to the file required applications installed and line number of their declaration. If the symbol is in multiple files it shows a list of all files which have itconfigured.
==== Integrates Well ====The header and footer You are completely customizablegoing to need to download the opengrok binary release tarball from [http://opensolaris. org/os/project/opengrok/ OpenGrok could be integrated with the current MDC potentially]. The header Untar it (tar zxf opengrok-0.7.tar.gz) and footer are implemented through a variable which holds make note of the copmlete html of directory you put it in. Next you will configure the header and footerfollowing variables in my script:<pre>#Mercurial Repository to useREPO=http://hg.mozilla.org/mozilla-central <-- Change to your HG Repo
#Base directory for contentsBASEDIR== Example Implementation ==[http://cvs.opensolaris.orghome/sourcejhford/ OpenSolaris]mozilla <-- This is the base directory for the OpenGrok data files and the HG repo
== Installation Procedure ==#This is the name of the data directory for OpenGrokDATADIR==== Notes ====I will be listing all commands and steps I use to setup data-dir <-- This is the plain OpenGrok so that it can be easily replicatedfolder *name* for opengrok's data==== Steps ====* Install Ubuntu Linux as a server from #This is the Ubuntu DVD* Install name of the following packagessource directory for OpenGrok SRCDIR=src- ctags dir <-> exuberant-ctagsThis is the folder *name* for opengrok's copy of HG code - sun-java5-jdk #OpenGrok install path - tomcat5Where is opengrok.jar? OGDIR="/home/jhford/opengrok/opengrok- Installs GNU Java which must be removed* Run 0.7"sudo update<-alternatives -this is where the OpenGrok tarball files ended up. It is likely where you ran "tar zxf opengrok-config java0.7.tar.gz" and  #OpenGrok source.war from opengrok tarballOGCONTEXT="grokzilla"apt<-get remove --purge java-gcj-compat"* Change this variable defines the tomcat5 config (grokzilla in http:/etc/defaultchina:8080/tomcat5) grokzilla OGWAR="${OGCONTEXT}.war" <-- Likely, you will never need to point to the new default Java runtime (change this #Your application server's .war deployment directoryWEBAPPDIR="/usrhome/libjhford/jvmtomcat/javaapache-1tomcat-6.50.018/webapps" <--sunThis is where your app server's war deployment folder is or where you want the resulting war file<pre> Then run the script and notice that you have opengrok! It will likely show up at http://jrelocalhost:8080/grokzilla
1
edit

Navigation menu