You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@poi.apache.org by ce...@apache.org on 2016/12/11 20:58:42 UTC

svn commit: r1773642 - /poi/trunk/view.sh

Author: centic
Date: Sun Dec 11 20:58:42 2016
New Revision: 1773642

URL: http://svn.apache.org/viewvc?rev=1773642&view=rev
Log:
Enhance view.sh for HWPF/doc files

Modified:
    poi/trunk/view.sh

Modified: poi/trunk/view.sh
URL: http://svn.apache.org/viewvc/poi/trunk/view.sh?rev=1773642&r1=1773641&r2=1773642&view=diff
==============================================================================
--- poi/trunk/view.sh (original)
+++ poi/trunk/view.sh Sun Dec 11 20:58:42 2016
@@ -1,7 +1,7 @@
-#!/bin/sh
+#!/bin/bash
 
 # find jar-file with highest version number
-for i in `ls build/dist/poi-*.jar | grep -v -- "-sources" | grep -v -- "-examples" | grep -v -- "-excelant" | grep -v -- "-ooxml" | grep -v -- "-scratchpad" | grep -v -- "-javadoc"`;do
+for i in `ls build/dist/poi-*.jar | grep -v -- "-sources" | grep -v -- "-examples" | grep -v -- "-excelant" | grep -v -- "-ooxml" | grep -v -- "-javadoc"`;do
 	CP=$i:$CP
 done
 
@@ -13,4 +13,11 @@ fi
 
 echo Using jar $CP
 
-java -cp $CP org.apache.poi.hssf.dev.BiffViewer --escher "$@"
+file=$1
+echo Found extension ${file: -4}
+if [ ${file: -4} == ".doc" ]
+then
+	java -cp $CP org.apache.poi.hwpf.dev.HWPFLister "$@" --pictures --escher
+else
+	java -cp $CP org.apache.poi.hssf.dev.BiffViewer --escher "$@"
+fi



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@poi.apache.org
For additional commands, e-mail: commits-help@poi.apache.org