diff --git a/packages/x11/other/ratpoison/init.d/73_ratpoison b/packages/x11/other/ratpoison/init.d/73_ratpoison deleted file mode 100644 index 7954754d97..0000000000 --- a/packages/x11/other/ratpoison/init.d/73_ratpoison +++ /dev/null @@ -1,37 +0,0 @@ -################################################################################ -# Copyright (C) 2009-2010 OpenELEC.tv -# http://www.openelec.tv -# -# This Program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2, or (at your option) -# any later version. -# -# This Program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with OpenELEC.tv; see the file COPYING. If not, write to -# the Free Software Foundation, 51 Franklin Street, Suite 500, Boston, MA 02110, USA. -# http://www.gnu.org/copyleft/gpl.html -################################################################################ - -# starting windowmanager -# -# runlevels: openelec - -( - progress "starting Windowmanager" - - # waiting for Xorg to start - wait_for_xorg - - # starting ratpoison - if [ -f /storage/.config/ratpoisonrc ]; then - exec ratpoison -f /storage/.config/ratpoisonrc -d :0.0 > /dev/null 2>&1 - else - exec ratpoison -d :0.0 > /dev/null 2>&1 - fi -)& diff --git a/packages/x11/other/ratpoison/package.mk b/packages/x11/other/ratpoison/package.mk index 8f7fbdf06c..15c27068c1 100644 --- a/packages/x11/other/ratpoison/package.mk +++ b/packages/x11/other/ratpoison/package.mk @@ -54,3 +54,7 @@ post_makeinstall_target() { mkdir -p $INSTALL/etc cp $PKG_DIR/config/ratpoisonrc $INSTALL/etc } + +post_install() { + enable_service ratpoison.service +} diff --git a/packages/x11/other/ratpoison/system.d/ratpoison.service b/packages/x11/other/ratpoison/system.d/ratpoison.service new file mode 100644 index 0000000000..24a2584cb5 --- /dev/null +++ b/packages/x11/other/ratpoison/system.d/ratpoison.service @@ -0,0 +1,13 @@ +[Unit] +Description=Ratpoison Window Manager +After=xorg-server.service +Requires=graphical.target + +[Service] +Environment=DISPLAY=:0.0 +ExecStart=/bin/sh -c 'sleep 1; exec /usr/bin/ratpoison' +KillMode=process +Restart=always + +[Install] +WantedBy=graphical.target