summaryrefslogtreecommitdiff
path: root/russian
diff options
context:
space:
mode:
authorEdwin Groothuis <edwin@FreeBSD.org>2005-11-04 06:18:23 +0000
committerEdwin Groothuis <edwin@FreeBSD.org>2005-11-04 06:18:23 +0000
commit6072e8dd86b68bbf4e67730f08885d2b8f3de9f2 (patch)
treeecd1c4fbf02d8f6edea6e1c16393896de7962a06 /russian
parentRevert to old method to be installed without execution permission (diff)
Unbreak port by using pkg-install and pkg-deinstall scripts.
Note to future submitters of ports: Don't throw away files from others ports.
Notes
Notes: svn path=/head/; revision=147188
Diffstat (limited to 'russian')
-rw-r--r--russian/pine.language/Makefile14
-rw-r--r--russian/pine.language/files/pkg-deinstall.in12
-rw-r--r--russian/pine.language/files/pkg-install.in21
3 files changed, 39 insertions, 8 deletions
diff --git a/russian/pine.language/Makefile b/russian/pine.language/Makefile
index 0d9c766d8984..e05880e323f6 100644
--- a/russian/pine.language/Makefile
+++ b/russian/pine.language/Makefile
@@ -15,19 +15,17 @@ COMMENT= Tune Pine for Russian (KOI8-R) defaults
RUN_DEPENDS= pine:${PORTSDIR}/mail/pine4
-BROKEN= Removes pine.conf at deinstallation
-DEPRECATED= ${BROKEN}
-EXPIRATION_DATE=2005-09-22
-
NO_WRKSUBDIR= YES
NO_BUILD= YES
-PLIST_FILES= etc/pine.conf
+
+SUB_FILES= pkg-install pkg-deinstall
+PKGINSTALL= ${WRKDIR}/pkg-install
+PKGDEINSTALL= ${WRKDIR}/pkg-deinstall
do-fetch:
+ ${DO_NADA}
do-install:
- ${GREP} -q -i koi8 ${PREFIX}/etc/pine.conf || \
- ${CAT} ${FILESDIR}/pine.add >> \
- ${PREFIX}/etc/pine.conf
+ @${SETENV} ${SCRIPTS_ENV} PGPLIB="${PGPLIB}" PKG_PREFIX="${PREFIX}" ${SH} ${PKGINSTALL} ${PKGNAME} pkg-install
.include <bsd.port.mk>
diff --git a/russian/pine.language/files/pkg-deinstall.in b/russian/pine.language/files/pkg-deinstall.in
new file mode 100644
index 000000000000..c2edb51d4fc4
--- /dev/null
+++ b/russian/pine.language/files/pkg-deinstall.in
@@ -0,0 +1,12 @@
+#!/bin/sh
+
+# $FreeBSD$
+
+cp %%LOCALBASE%%/etc/pine.conf %%LOCALBASE%%/etc/pine.conf.bak
+
+z=`grep -n "RUSSIAN PINE - DO NOT DELETE THIS LINE" %%LOCALBASE%%/etc/pine.conf | awk -F: '{ print $1 }'`
+z=`echo $z | sed -e 's/ /,/'`
+
+sed -e "${z}d" < %%LOCALBASE%%/etc/pine.conf.bak > %%LOCALBASE%%/etc/pine.conf
+
+rm %%LOCALBASE%%/etc/pine.conf.bak
diff --git a/russian/pine.language/files/pkg-install.in b/russian/pine.language/files/pkg-install.in
new file mode 100644
index 000000000000..845e99ff664c
--- /dev/null
+++ b/russian/pine.language/files/pkg-install.in
@@ -0,0 +1,21 @@
+#!/bin/sh
+
+# $FreeBSD$
+
+if ! grep -q -i koi8 %%LOCALBASE%%/etc/pine.conf; then
+ echo "#### RUSSIAN PINE - DO NOT DELETE THIS LINE ####
+############################### Preferences ################################
+
+# List of features; see Pine's Setup/options menu for the current set.
+# e.g. feature-list= select-without-confirm, signature-at-bottom
+# Default condition for all of the features is no-.
+feature-list=enable-8bit-esmtp-negotiation,
+ enable-8bit-nntp-posting,
+ pass-control-characters-as-is
+
+# Reflects capabilities of the display you have. Default: US-ASCII.
+# Typical alternatives include ISO-8859-x, (x is a number between 1 and 9).
+character-set=KOI8-R
+#### RUSSIAN PINE - DO NOT DELETE THIS LINE ####" \
+ >> %%LOCALBASE%%/etc/pine.conf
+fi