* updated kmousetool (21.12.1 -> 21.12.2), untested
[t2-trunk.git] / package / base / sysvinit / stone_mod_init.sh
blob767ee86494057132df1c8bfb37aec922e2e1c4ab
1 # --- T2-COPYRIGHT-NOTE-BEGIN ---
2 # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
3 #
4 # T2 SDE: package/.../sysvinit/stone_mod_init.sh
5 # Copyright (C) 2004 - 2005 The T2 SDE Project
6 # Copyright (C) 1998 - 2003 ROCK Linux Project
7 #
8 # More information can be found in the files COPYING and README.
9 #
10 # This program is free software; you can redistribute it and/or modify
11 # it under the terms of the GNU General Public License as published by
12 # the Free Software Foundation; version 2 of the License. A copy of the
13 # GNU General Public License can be found in the file COPYING.
14 # --- T2-COPYRIGHT-NOTE-END ---
16 # [MAIN] 85 init System Init Configuration
18 write_config() {
19 cp /etc/inittab{,.new}
20 sed s/.:initdefault/$rl:initdefault/ /etc/inittab.new > /etc/inittab
21 rm -f /etc/inittab.new
24 set_rl() {
25 gui_menu default_runlevel "Select the default runlevel (Current: $rl)" \
26 '1 ... Single user mode' 'rl=1' \
27 '2 ... Multi user mode without network' 'rl=2' \
28 '3 ... Multi user mode (normal operation)' 'rl=3' \
29 '4 ... Custom use' 'rl=4' \
30 '5 ... Multi user mode with graphical login manager' 'rl=5'
32 write_config
35 main() {
36 while
37 rl=`grep initdefault /etc/inittab | cut -d : -f2`
39 gui_menu gpm 'System Init Configuration.
40 Select an item to change the value:' \
41 "Default runlevel... $rl" 'set_rl' \
42 '' '' \
43 'Edit the /etc/inittab file' \
44 "gui_edit 'The inittab file' /etc/inittab"
45 do : ; done