[arch-commits] Commit in polipo/trunk (PKGBUILD polipo.install)

Jan Steffens heftig at archlinux.org
Thu Jul 28 19:19:58 UTC 2016


    Date: Thursday, July 28, 2016 @ 19:19:57
  Author: heftig
Revision: 184574

1.1.1-2

Modified:
  polipo/trunk/PKGBUILD
  polipo/trunk/polipo.install

----------------+
 PKGBUILD       |    2 +-
 polipo.install |   38 ++------------------------------------
 2 files changed, 3 insertions(+), 37 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2016-07-28 19:19:26 UTC (rev 184573)
+++ PKGBUILD	2016-07-28 19:19:57 UTC (rev 184574)
@@ -8,7 +8,7 @@
 
 pkgname=polipo
 pkgver=1.1.1
-pkgrel=1
+pkgrel=2
 pkgdesc="A small and fast caching web proxy."
 arch=('i686' 'x86_64')
 url="http://www.pps.jussieu.fr/~jch/software/polipo/"

Modified: polipo.install
===================================================================
--- polipo.install	2016-07-28 19:19:26 UTC (rev 184573)
+++ polipo.install	2016-07-28 19:19:57 UTC (rev 184574)
@@ -1,6 +1,3 @@
-infodir=/usr/share/info
-filelist=(polipo.info)
-
 create_polipo_user() {
   getent group polipo &>/dev/null || groupadd -g 185 polipo >/dev/null
   getent passwd polipo &>/dev/null || useradd -u 185 -g polipo \
@@ -10,42 +7,11 @@
 }
 
 post_install() {
-  [ -x usr/bin/install-info ] || return 0
-  for file in ${filelist[@]}; do
-    install-info $infodir/$file $infodir/dir 2> /dev/null
-  done
-  create_polipo_user
+  post_upgrade $1 ''
 }
 
 post_upgrade() {
-  if [[ $(vercmp $2 1.0.4.1-11) -le 0 ]]; then
-    echo Stopping polipo service in order to modify the user/group.
-    systemctl stop polipo
-
-    # in case the user/group were already created as recommended by the wiki
-    userdel polipo &>/dev/null
-    groupdel polipo &>/dev/null
-
-    create_polipo_user
-    chown -R 185:185 /var/cache/polipo
-
-    echo You may now restart the polipo service.
-  fi
-
-  post_install $1
+  create_polipo_user
 }
 
-pre_remove() {
-  [ -x usr/bin/install-info ] || return 0
-  for file in ${filelist[@]}; do
-    install-info --delete $infodir/$file $infodir/dir 2> /dev/null
-  done
-}
-
-post_remove() {
-  getent passwd polipo &>/dev/null && userdel polipo >/dev/null
-  getent group polipo &>/dev/null && groupdel polipo >/dev/null
-  true
-}
-
 # vim:set ts=2 sw=2 et:



More information about the arch-commits mailing list