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

Antonio Rojas arojas at archlinux.org
Sun Jan 11 10:30:46 UTC 2015


    Date: Sunday, January 11, 2015 @ 11:30:45
  Author: arojas
Revision: 125719

Remove sagemath user (FS#43370)

Modified:
  sage-notebook/trunk/PKGBUILD
  sage-notebook/trunk/sage-notebook.install

-----------------------+
 PKGBUILD              |    2 +-
 sage-notebook.install |   15 ++++++---------
 2 files changed, 7 insertions(+), 10 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2015-01-11 03:30:40 UTC (rev 125718)
+++ PKGBUILD	2015-01-11 10:30:45 UTC (rev 125719)
@@ -3,7 +3,7 @@
 
 pkgname=sage-notebook
 pkgver=0.11.1
-pkgrel=2
+pkgrel=3
 pkgdesc='Web-based notebook interface for Sage'
 arch=('any')
 url='http://www.sagemath.org'

Modified: sage-notebook.install
===================================================================
--- sage-notebook.install	2015-01-11 03:30:40 UTC (rev 125718)
+++ sage-notebook.install	2015-01-11 10:30:45 UTC (rev 125719)
@@ -1,17 +1,14 @@
 post_install() {
   update-desktop-database -q
 
-  # add sagemath user for the daemon
-  useradd -r -c 'Sage daemon' -d /var/lib/sage -s /bin/false sagemath
+  getent passwd sagemath > /dev/null && userdel sagemath
 }
 
 post_upgrade() {
-  post_install $1
-  echo "There is now a user session unit included to run a sage notebook as your user."
-  echo "The wiki includes a guide on starting systemd user sessions"
+  update-desktop-database -q
+
+  if [ "$(vercmp $2 0.11.1-3)" -lt 0 ]; then
+    getent passwd sagemath > /dev/null && userdel sagemath 
+  fi
 }
 
-post_remove() {
-  # remove the sagemath daemon user
-  userdel sagemath
-}



More information about the arch-commits mailing list