From 79012b16101aef95da0aa1bf99e73f0aeef2678d Mon Sep 17 00:00:00 2001 From: AlmAck Date: Wed, 8 Oct 2014 19:35:50 +0000 Subject: [PATCH] sage-mathematics sync files --- sage-mathematics/sage-mathematics.install | 6 ++---- .../{SAGE-notebook.desktop => sage-notebook.desktop} | 2 +- sage-mathematics/sage.service | 8 ++++++++ 3 files changed, 11 insertions(+), 5 deletions(-) rename sage-mathematics/{SAGE-notebook.desktop => sage-notebook.desktop} (84%) create mode 100644 sage-mathematics/sage.service diff --git a/sage-mathematics/sage-mathematics.install b/sage-mathematics/sage-mathematics.install index ab5dae235..6c55dad2b 100644 --- a/sage-mathematics/sage-mathematics.install +++ b/sage-mathematics/sage-mathematics.install @@ -2,10 +2,6 @@ post_install() { cd /opt/sage update-desktop-database -q - # set HOME because when sage updates its sage_root (after being moved) it will write files to ~/.sage with root ownership - # the files it writes to ~/.sage can be safely ignored - HOME=/tmp ./sage -c - # add sagemath user for the daemon useradd -r -c 'Sage daemon' -d /opt/sage -s /bin/false sagemath @@ -41,6 +37,8 @@ echo ' 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" } post_remove() { diff --git a/sage-mathematics/SAGE-notebook.desktop b/sage-mathematics/sage-notebook.desktop similarity index 84% rename from sage-mathematics/SAGE-notebook.desktop rename to sage-mathematics/sage-notebook.desktop index e3c1d4d7f..91ddc7562 100644 --- a/sage-mathematics/SAGE-notebook.desktop +++ b/sage-mathematics/sage-notebook.desktop @@ -6,7 +6,7 @@ Comment[en_US]=SAGE NOTEBOOK Exec=/opt/sage/sage -notebook GenericName= GenericName[de]= -Icon=/opt/sage/devel/ext-main/notebook/images/sageicon.png +Icon=/usr/share/pixmaps/sage-notebook.png MimeType= Name[de]=SAGE StartupNotify=true diff --git a/sage-mathematics/sage.service b/sage-mathematics/sage.service new file mode 100644 index 000000000..d999414de --- /dev/null +++ b/sage-mathematics/sage.service @@ -0,0 +1,8 @@ +[Unit] +Description=A free open-source mathematics software system + +[Service] +ExecStart=/opt/sage/sage -n + +[Install] +WantedBy=default.target