mirror of
https://github.com/Ponce/slackbuilds
synced 2024-11-16 19:50:19 +01:00
python/html2text: Updated for version 2020.1.16, new maintainer.
Signed-off-by: B. Watson <yalhcru@gmail.com>
This commit is contained in:
parent
c44ac2bb36
commit
3bdd47985e
4 changed files with 35 additions and 40 deletions
|
@ -1,3 +1,8 @@
|
|||
html2text (Python HTML-to-text converter)
|
||||
html2text (turn HTML into equivalent Markdown-structured text)
|
||||
|
||||
It turns HTML into equivalent Markdown-structured text.
|
||||
html2text is a Python script that converts a page of HTML into clean,
|
||||
easy-to-read plain ASCII text. Better yet, that ASCII also happens to
|
||||
be valid Markdown (a text-to-HTML format).
|
||||
|
||||
html2text can be used as a standalone program ("html2text --help" for
|
||||
usage) or as a Python library (import html2text).
|
||||
|
|
|
@ -2,8 +2,9 @@
|
|||
|
||||
# Slackware build script for html2text
|
||||
|
||||
# Copyright 2011 crocket (crockabiscuit@gmail.com)
|
||||
# Copyright 2011 crocket (email removed)
|
||||
# Copyright 2013-2015 LukenShiro, Italy
|
||||
# Copyright 2020 B. Watson
|
||||
# All rights reserved.
|
||||
#
|
||||
# Redistribution and use of this script, with or without modification, is
|
||||
|
@ -23,14 +24,22 @@
|
|||
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
|
||||
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
# 20200203 bkw:
|
||||
# - new maintainer
|
||||
# - i486 => i586
|
||||
# - upstream dropped support for python 2.x, so require python3
|
||||
# - expand README and slack-desc
|
||||
# - get rid of unused template code
|
||||
# - don't install test/ in docdir
|
||||
|
||||
PRGNAM=html2text
|
||||
VERSION=${VERSION:-2015.11.4}
|
||||
VERSION=${VERSION:-2020.1.16}
|
||||
BUILD=${BUILD:-1}
|
||||
TAG=${TAG:-_SBo}
|
||||
|
||||
if [ -z "$ARCH" ]; then
|
||||
case "$( uname -m )" in
|
||||
i?86) ARCH=i486 ;;
|
||||
i?86) ARCH=i586 ;;
|
||||
arm*) ARCH=arm ;;
|
||||
*) ARCH=$( uname -m ) ;;
|
||||
esac
|
||||
|
@ -41,22 +50,6 @@ TMP=${TMP:-/tmp/SBo}
|
|||
PKG=$TMP/package-$PRGNAM
|
||||
OUTPUT=${OUTPUT:-/tmp}
|
||||
|
||||
if [ "$ARCH" = "i486" ]; then
|
||||
SLKCFLAGS="-O2 -march=i486 -mtune=i686"
|
||||
LIBDIRSUFFIX=""
|
||||
elif [ "$ARCH" = "i686" ]; then
|
||||
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
|
||||
LIBDIRSUFFIX=""
|
||||
elif [ "$ARCH" = "x86_64" ]; then
|
||||
SLKCFLAGS="-O2 -fPIC"
|
||||
LIBDIRSUFFIX="64"
|
||||
else
|
||||
SLKCFLAGS="-O2"
|
||||
LIBDIRSUFFIX=""
|
||||
fi
|
||||
|
||||
DOCFILES="AUTHORS.rst ChangeLog.rst COPYING README.md test/"
|
||||
|
||||
set -e
|
||||
|
||||
rm -rf $PKG
|
||||
|
@ -66,16 +59,13 @@ rm -rf $PRGNAM-$VERSION
|
|||
tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
|
||||
cd $PRGNAM-$VERSION
|
||||
chown -R root:root .
|
||||
find -L . \
|
||||
\( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
|
||||
-o -perm 511 \) -exec chmod 755 {} \; -o \
|
||||
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
|
||||
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
|
||||
find -L . -perm /111 -a \! -perm 755 -a -exec chmod 755 {} \+ -o \
|
||||
\! -perm /111 -a \! -perm 644 -a -exec chmod 644 {} \+
|
||||
|
||||
python setup.py install --root=$PKG
|
||||
python3 setup.py install --root=$PKG
|
||||
|
||||
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
|
||||
cp -a $DOCFILES $PKG/usr/doc/$PRGNAM-$VERSION/
|
||||
cp -a *.rst *.md COPYING $PKG/usr/doc/$PRGNAM-$VERSION/
|
||||
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
|
||||
|
||||
mkdir -p $PKG/install
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
PRGNAM="html2text"
|
||||
VERSION="2015.11.4"
|
||||
VERSION="2020.1.16"
|
||||
HOMEPAGE="https://github.com/Alir3z4/html2text"
|
||||
DOWNLOAD="https://pypi.python.org/packages/source/h/html2text/html2text-2015.11.4.tar.gz"
|
||||
MD5SUM="51bdf631d39ba577b8b66497fb17aed9"
|
||||
DOWNLOAD="https://pypi.python.org/packages/source/h/html2text/html2text-2020.1.16.tar.gz"
|
||||
MD5SUM="c77b580c94d1a9e0145f23cc4472993d"
|
||||
DOWNLOAD_x86_64=""
|
||||
MD5SUM_x86_64=""
|
||||
REQUIRES=""
|
||||
MAINTAINER="LukenShiro"
|
||||
EMAIL="lukenshiro@ngi.it"
|
||||
REQUIRES="python3"
|
||||
MAINTAINER="B. Watson"
|
||||
EMAIL="yalhcru@gmail.com"
|
||||
|
|
|
@ -6,14 +6,14 @@
|
|||
# customary to leave one space after the ':' except on otherwise blank lines.
|
||||
|
||||
|-----handy-ruler------------------------------------------------------|
|
||||
html2text: html2text (Python HTML-to-text converter)
|
||||
html2text:
|
||||
html2text: It turns HTML into equivalent Markdown-structured text.
|
||||
html2text:
|
||||
html2text: Homepage: http://www.aaronsw.com/2002/html2text
|
||||
html2text:
|
||||
html2text: html2text (turn HTML into equivalent Markdown-structured text)
|
||||
html2text:
|
||||
html2text: html2text is a Python script that converts a page of HTML into clean,
|
||||
html2text: easy-to-read plain ASCII text. Better yet, that ASCII also happens
|
||||
html2text: to be valid Markdown (a text-to-HTML format).
|
||||
html2text:
|
||||
html2text: html2text can be used as a standalone program ("html2text --help"
|
||||
html2text: for usage) or as a Python library (import html2text).
|
||||
html2text:
|
||||
html2text:
|
||||
html2text:
|
||||
|
|
Loading…
Reference in a new issue