From 57ea6f78a953eece9ed0b929aa7aad85033f8a7f Mon Sep 17 00:00:00 2001 From: sip Date: Sun, 8 Jan 2006 14:35:03 +0000 Subject: [PATCH] restored the daemon config option, updated copyright info for 2006 --- ChangeLog | 2 ++ README | 4 ++-- app.cpp | 8 ++++++-- app.h | 4 ++-- cfg.cpp | 5 +++-- cfg.h | 4 ++-- const.h | 4 ++-- image.cpp | 4 ++-- image.h | 4 ++-- input.cpp | 4 ++-- input.h | 4 ++-- main.cpp | 4 ++-- numlock.cpp | 4 ++-- numlock.h | 4 ++-- panel.cpp | 4 ++-- panel.h | 4 ++-- slim.conf | 6 +++++- switchuser.cpp | 4 ++-- switchuser.h | 4 ++-- 19 files changed, 46 insertions(+), 35 deletions(-) diff --git a/ChangeLog b/ChangeLog index 7e13049..fda5c71 100644 --- a/ChangeLog +++ b/ChangeLog @@ -3,6 +3,8 @@ (i.e. for session registering) * Added automatic numlock on/off option * Support for numpad Enter key + * restored support for daemon option in the config + file. 1.2.3 - 2005.09.11 * Added FreeBSD, NetBSD, OpenBSD support diff --git a/README b/README index c3bee63..e30fbf1 100644 --- a/README +++ b/README @@ -21,7 +21,7 @@ INSTALLATION USAGE - To launch slim, execute run the slim binary, + To launch slim, execute run the slim binary, followed by the -d option if you want it to run as a daemon in the background (reccommended) @@ -47,7 +47,7 @@ THEMES See THEMES COPYRIGHT - SLiM is copyright (c) 2004-05 by Simone Rota, Johannes Winkelmann + SLiM is copyright (c) 2004-06 by Simone Rota, Johannes Winkelmann and is available under the GNU General Public License. See the COPYING file for the complete license. diff --git a/app.cpp b/app.cpp index 424b800..08b0c44 100644 --- a/app.cpp +++ b/app.cpp @@ -1,7 +1,7 @@ /* SLiM - Simple Login Manager Copyright (C) 1997, 1998 Per Liden - Copyright (C) 2004-05 Simone Rota - Copyright (C) 2004-05 Johannes Winkelmann + Copyright (C) 2004-06 Simone Rota + Copyright (C) 2004-06 Johannes Winkelmann 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 @@ -166,6 +166,10 @@ void App::Run() { #ifndef XNEST_DEBUG OpenLog(); + + if (cfg.getOption("daemon") == "yes") { + daemonmode = true; + } // Daemonize if (daemonmode) { diff --git a/app.h b/app.h index de86703..495517f 100644 --- a/app.h +++ b/app.h @@ -1,7 +1,7 @@ /* SLiM - Simple Login Manager Copyright (C) 1997, 1998 Per Liden - Copyright (C) 2004-05 Simone Rota - Copyright (C) 2004-05 Johannes Winkelmann + Copyright (C) 2004-06 Simone Rota + Copyright (C) 2004-06 Johannes Winkelmann 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 diff --git a/cfg.cpp b/cfg.cpp index ce49e8e..d8e6b4d 100644 --- a/cfg.cpp +++ b/cfg.cpp @@ -1,6 +1,6 @@ /* SLiM - Simple Login Manager - Copyright (C) 2004-05 Simone Rota - Copyright (C) 2004-05 Johannes Winkelmann + Copyright (C) 2004-06 Simone Rota + Copyright (C) 2004-06 Johannes Winkelmann 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 @@ -25,6 +25,7 @@ Cfg::Cfg() { options.insert(option("default_xserver","/usr/X11R6/bin/X")); options.insert(option("xserver_arguments","")); options.insert(option("numlock","")); + options.insert(option("daemon","")); options.insert(option("login_cmd","exec /bin/bash -login ~/.xinitrc %session")); options.insert(option("halt_cmd","/sbin/shutdown -h now")); options.insert(option("reboot_cmd","/sbin/shutdown -r now")); diff --git a/cfg.h b/cfg.h index 38cb081..49d578f 100644 --- a/cfg.h +++ b/cfg.h @@ -1,6 +1,6 @@ /* SLiM - Simple Login Manager - Copyright (C) 2004-05 Simone Rota - Copyright (C) 2004-05 Johannes Winkelmann + Copyright (C) 2004-06 Simone Rota + Copyright (C) 2004-06 Johannes Winkelmann 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 diff --git a/const.h b/const.h index f05966c..140065b 100644 --- a/const.h +++ b/const.h @@ -1,7 +1,7 @@ /* SLiM - Simple Login Manager Copyright (C) 1997, 1998 Per Liden - Copyright (C) 2004-05 Simone Rota - Copyright (C) 2004-05 Johannes Winkelmann + Copyright (C) 2004-06 Simone Rota + Copyright (C) 2004-06 Johannes Winkelmann 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 diff --git a/image.cpp b/image.cpp index 84cad31..15433de 100644 --- a/image.cpp +++ b/image.cpp @@ -1,6 +1,6 @@ /* SLiM - Simple Login Manager - Copyright (C) 2004-05 Simone Rota - Copyright (C) 2004-05 Johannes Winkelmann + Copyright (C) 2004-06 Simone Rota + Copyright (C) 2004-06 Johannes Winkelmann 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 diff --git a/image.h b/image.h index 3d58679..74b4e45 100644 --- a/image.h +++ b/image.h @@ -1,6 +1,6 @@ /* SLiM - Simple Login Manager - Copyright (C) 2004-05 Simone Rota - Copyright (C) 2004-05 Johannes Winkelmann + Copyright (C) 2004-06 Simone Rota + Copyright (C) 2004-06 Johannes Winkelmann 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 diff --git a/input.cpp b/input.cpp index fa221d9..9b086d1 100644 --- a/input.cpp +++ b/input.cpp @@ -1,7 +1,7 @@ /* SLiM - Simple Login Manager Copyright (C) 1997, 1998 Per Liden - Copyright (C) 2004-05 Simone Rota - Copyright (C) 2004-05 Johannes Winkelmann + Copyright (C) 2004-06 Simone Rota + Copyright (C) 2004-06 Johannes Winkelmann 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 diff --git a/input.h b/input.h index c4cf783..d453960 100644 --- a/input.h +++ b/input.h @@ -1,7 +1,7 @@ /* SLiM - Simple Login Manager Copyright (C) 1997, 1998 Per Liden - Copyright (C) 2004-05 Simone Rota - Copyright (C) 2004-05 Johannes Winkelmann + Copyright (C) 2004-06 Simone Rota + Copyright (C) 2004-06 Johannes Winkelmann 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 diff --git a/main.cpp b/main.cpp index 8820ef2..7710847 100644 --- a/main.cpp +++ b/main.cpp @@ -1,7 +1,7 @@ /* SLiM - Simple Login Manager Copyright (C) 1997, 1998 Per Liden - Copyright (C) 2004-05 Simone Rota - Copyright (C) 2004-05 Johannes Winkelmann + Copyright (C) 2004-06 Simone Rota + Copyright (C) 2004-06 Johannes Winkelmann 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 diff --git a/numlock.cpp b/numlock.cpp index 5432604..4b625ad 100644 --- a/numlock.cpp +++ b/numlock.cpp @@ -1,6 +1,6 @@ /* SLiM - Simple Login Manager - Copyright (C) 2004-05 Simone Rota - Copyright (C) 2004-05 Johannes Winkelmann + Copyright (C) 2004-06 Simone Rota + Copyright (C) 2004-06 Johannes Winkelmann 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 diff --git a/numlock.h b/numlock.h index 8158287..68c2a2c 100644 --- a/numlock.h +++ b/numlock.h @@ -1,6 +1,6 @@ /* SLiM - Simple Login Manager - Copyright (C) 2004-05 Simone Rota - Copyright (C) 2004-05 Johannes Winkelmann + Copyright (C) 2004-06 Simone Rota + Copyright (C) 2004-06 Johannes Winkelmann 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 diff --git a/panel.cpp b/panel.cpp index 8218e78..85dd87d 100644 --- a/panel.cpp +++ b/panel.cpp @@ -1,7 +1,7 @@ /* SLiM - Simple Login Manager Copyright (C) 1997, 1998 Per Liden - Copyright (C) 2004-05 Simone Rota - Copyright (C) 2004-05 Johannes Winkelmann + Copyright (C) 2004-06 Simone Rota + Copyright (C) 2004-06 Johannes Winkelmann 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 diff --git a/panel.h b/panel.h index 330b17f..915d17c 100644 --- a/panel.h +++ b/panel.h @@ -1,7 +1,7 @@ /* SLiM - Simple Login Manager Copyright (C) 1997, 1998 Per Liden - Copyright (C) 2004-05 Simone Rota - Copyright (C) 2004-05 Johannes Winkelmann + Copyright (C) 2004-06 Simone Rota + Copyright (C) 2004-06 Johannes Winkelmann 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 diff --git a/slim.conf b/slim.conf index 6172309..ac035eb 100644 --- a/slim.conf +++ b/slim.conf @@ -26,10 +26,14 @@ login_cmd exec /bin/bash -login ~/.xinitrc %session # Commands executed when starting and exiting a session. # They can be used for registering a X11 session with # sessreg. You can use the %user variable - +# # sessionstart_cmd some command # sessionstop_cmd some command +# Start in daemon mode. Valid values: yes | no +# Note that this can overridden by the command line +# option "-d" +# daemon yes # Available sessions (first one is the default). # The current chosen session name is replaced in the login_cmd diff --git a/switchuser.cpp b/switchuser.cpp index df933dd..31cab9a 100644 --- a/switchuser.cpp +++ b/switchuser.cpp @@ -1,7 +1,7 @@ /* SLiM - Simple Login Manager Copyright (C) 1997, 1998 Per Liden - Copyright (C) 2004-05 Simone Rota - Copyright (C) 2004-05 Johannes Winkelmann + Copyright (C) 2004-06 Simone Rota + Copyright (C) 2004-06 Johannes Winkelmann 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 diff --git a/switchuser.h b/switchuser.h index 341f9f0..b07880e 100644 --- a/switchuser.h +++ b/switchuser.h @@ -1,7 +1,7 @@ /* SLiM - Simple Login Manager Copyright (C) 1997, 1998 Per Liden - Copyright (C) 2004-05 Simone Rota - Copyright (C) 2004-05 Johannes Winkelmann + Copyright (C) 2004-06 Simone Rota + Copyright (C) 2004-06 Johannes Winkelmann 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