diff options
author | Phillip Warner <pc_warner@yahoo.com> | 2014-03-24 09:31:21 +0700 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2014-03-24 13:02:14 +0700 |
commit | ab09016092f9b536dd1992fcc16aae9d08c3e3e9 (patch) | |
tree | e6dd39bd857aed6f4a5c8d87f383b1c7c3c60f85 /office/docx2txt | |
parent | fe35329a9cdeb8c8eb03623afa9171da4e0617bb (diff) |
office/docx2txt: Added (docx to text converter).
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'office/docx2txt')
-rw-r--r-- | office/docx2txt/README | 4 | ||||
-rw-r--r-- | office/docx2txt/docx2txt.1.gz | bin | 0 -> 1225 bytes | |||
-rw-r--r-- | office/docx2txt/docx2txt.SlackBuild | 44 | ||||
-rw-r--r-- | office/docx2txt/docx2txt.info | 10 | ||||
-rw-r--r-- | office/docx2txt/doinst.sh | 13 | ||||
-rw-r--r-- | office/docx2txt/slack-desc | 19 |
6 files changed, 90 insertions, 0 deletions
diff --git a/office/docx2txt/README b/office/docx2txt/README new file mode 100644 index 000000000000..60b830d96de5 --- /dev/null +++ b/office/docx2txt/README @@ -0,0 +1,4 @@ +docx2txt - docx to text converter + +docx2txt is a perl based command line utility to convert Microsoft Office OOXML +(docx) documents to equivalent ASCII text documents. diff --git a/office/docx2txt/docx2txt.1.gz b/office/docx2txt/docx2txt.1.gz Binary files differnew file mode 100644 index 000000000000..615ea71e0d3d --- /dev/null +++ b/office/docx2txt/docx2txt.1.gz diff --git a/office/docx2txt/docx2txt.SlackBuild b/office/docx2txt/docx2txt.SlackBuild new file mode 100644 index 000000000000..ccc1351c2f88 --- /dev/null +++ b/office/docx2txt/docx2txt.SlackBuild @@ -0,0 +1,44 @@ +#!/bin/sh + +# Slackware build script for docx2txt +# Written by Phillip Warner <pc_warner@yahoo.com> + +PRGNAM=docx2txt +VERSION=${VERSION:-1.2} +ARCH=noarch +BUILD=${BUILD:-1} +TAG=${TAG:-_SBo} + +CWD=$(pwd) +TMP=${TMP:-/tmp/SBo} +PKG=$TMP/package-$PRGNAM +OUTPUT=${OUTPUT:-/tmp} + +set -e + +rm -rf $PKG +mkdir -p $TMP $PKG $OUTPUT +cd $TMP +rm -rf $PRGNAM-$VERSION +tar xvf $CWD/$PRGNAM-$VERSION.tgz +cd $PRGNAM-$VERSION + +chown -R root:root . + +mkdir -p $PKG/usr/bin \ + $PKG/etc \ + $PKG/usr/man/man1 \ + $PKG/usr/doc/$PRGNAM-$VERSION \ + $PKG/install + +install -m 0755 docx2txt.pl $PKG/usr/bin/docx2txt +install -m 0644 docx2txt.config $PKG/etc/docx2txt.config.new +install -m 0644 $CWD/docx2txt.1.gz $PKG/usr/man/man1/docx2txt.1.gz +install -m 0644 AUTHORS COPYING ChangeLog README ToDo $PKG/usr/doc/$PRGNAM-$VERSION/ + +cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild +cat $CWD/slack-desc > $PKG/install/slack-desc +cat $CWD/doinst.sh > $PKG/install/doinst.sh + +cd $PKG +/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz} diff --git a/office/docx2txt/docx2txt.info b/office/docx2txt/docx2txt.info new file mode 100644 index 000000000000..58cf1e112ef9 --- /dev/null +++ b/office/docx2txt/docx2txt.info @@ -0,0 +1,10 @@ +PRGNAM="docx2txt" +VERSION="1.2" +HOMEPAGE="http://docx2txt.sourceforge.net" +DOWNLOAD="http://sourceforge.net/projects/docx2txt/files/docx2txt/v1.2/docx2txt-1.2.tgz" +MD5SUM="7f1d0950b352b87398c8d2073a5b766e" +DOWNLOAD_x86_64="" +MD5SUM_x86_64="" +REQUIRES="" +MAINTAINER="Phillip Warner" +EMAIL="pc_warner@yahoo.com" diff --git a/office/docx2txt/doinst.sh b/office/docx2txt/doinst.sh new file mode 100644 index 000000000000..0e4f91f5d0fe --- /dev/null +++ b/office/docx2txt/doinst.sh @@ -0,0 +1,13 @@ +config() { + NEW="$1" + OLD="$(dirname $NEW)/$(basename $NEW .new)" + # If there's no config file by that name, mv it over: + if [ ! -r $OLD ]; then + mv $NEW $OLD + elif [ "$(cat $OLD | md5sum)" = "$(cat $NEW | md5sum)" ]; then + # toss the redundant copy + rm $NEW + fi + # Otherwise, we leave the .new copy for the admin to consider... +} +config etc/docx2txt.config.new diff --git a/office/docx2txt/slack-desc b/office/docx2txt/slack-desc new file mode 100644 index 000000000000..5ff94d193e74 --- /dev/null +++ b/office/docx2txt/slack-desc @@ -0,0 +1,19 @@ +# HOW TO EDIT THIS FILE: +# The "handy ruler" below makes it easier to edit a package description. +# Line up the first '|' above the ':' following the base package name, and +# the '|' on the right side marks the last column you can put a character in. +# You must make exactly 11 lines for the formatting to be correct. It's also +# customary to leave one space after the ':' except on otherwise blank lines. + + |-----handy-ruler------------------------------------------------------| +docx2txt: docx2txt (docx to text converter) +docx2txt: +docx2txt: docx2txt is a perl based command line utility to convert Microsoft +docx2txt: Office OOXML (docx) documents to equivalent ASCII text documents. +docx2txt: +docx2txt: Homepage: http://docx2txt.sourceforge.net +docx2txt: +docx2txt: +docx2txt: +docx2txt: +docx2txt: |