openGrok 配置
ubuntu + jdk 1.8 + tomcat 8 + opengrok-0.12.1
1. 安装jdk
2. 下载并安装tomcat 8
muhe221@muhe221-TP:~/server/apache-tomcat-8.0.22/bin$ ./startup.sh
Using CATALINA_BASE: /home/muhe221/server/apache-tomcat-8.0.22
Using CATALINA_HOME: /home/muhe221/server/apache-tomcat-8.0.22
Using CATALINA_TMPDIR: /home/muhe221/server/apache-tomcat-8.0.22/temp
Using JRE_HOME: /home/muhe221/soft/jdk1.8.0_25
Using CLASSPATH: /home/muhe221/server/apache-tomcat-8.0.22/bin/bootstrap.jar:/home/muhe221/server/apache-tomcat-8.0.22/bin/tomcat-juli.jar
Tomcat started.
http://127.0.0.1:8080 能打开则表示tomcat安装成功
3 下载opengrok-0.12.1
/home/muhe221/server/opengrok-0.12.1/lib/source.war拷贝到/home/muhe221/server/apache-tomcat-8.0.22/webapps目录下
http://127.0.0.1:8080/source/ 能打开,但是还没有导入源码。
$sudo apt-get install ctags
muhe221@muhe221-TP:~/server/opengrok-0.12.1/bin$ sudo -s
root@muhe221-TP:~/server/opengrok-0.12.1/bin# ./OpenGrok index /home/muhe221/code/chameleon //导入代码,建立索引
Loading the default instance configuration ...
root@muhe221-TP:~/server/opengrok-0.12.1/bin#
再次访问127.0.0.1:8080/source/ 发现有建立的索引等相关功能。
到此结束,可以用自己的电脑弄了个 看代码真是爽歪歪

浙公网安备 33010602011771号