2003-09-07 19:51:59 +00:00
|
|
|
#!/bin/sh
|
2004-11-19 11:37:27 +00:00
|
|
|
# $Id$
|
2005-03-17 00:05:50 +00:00
|
|
|
|
|
|
|
command="`basename \"$0\"`"
|
2006-04-17 09:47:40 +00:00
|
|
|
startup="$HOME/.fluxbox/startup"
|
2005-03-17 00:05:50 +00:00
|
|
|
|
|
|
|
while [ $# -gt 0 ]; do
|
|
|
|
case "$1" in
|
|
|
|
-c|--config)
|
|
|
|
if [ $# -lt 2 ]; then
|
|
|
|
echo "$command:error, missing argument"
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
shift
|
|
|
|
startup=$1
|
|
|
|
;;
|
|
|
|
-h|--help) cat <<EOF
|
|
|
|
Usage: $command [-h] [-c startupfile]
|
|
|
|
EOF
|
|
|
|
exit
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
shift
|
|
|
|
done
|
|
|
|
|
|
|
|
if [ -x "$startup" ]; then
|
|
|
|
exec "$startup"
|
|
|
|
elif [ -r "$startup" ]; then
|
|
|
|
exec sh "$startup"
|
2003-09-07 19:51:59 +00:00
|
|
|
else
|
2006-04-17 09:47:40 +00:00
|
|
|
if [ ! -d "$HOME/.fluxbox" ]; then
|
|
|
|
mkdir -p "$HOME/.fluxbox/backgrounds" "$HOME/.fluxbox/styles" "$HOME/.fluxbox/pixmaps"
|
2003-09-07 19:51:59 +00:00
|
|
|
fi
|
2005-03-17 00:05:50 +00:00
|
|
|
if [ ! -r "$startup" ]; then
|
2005-04-09 07:46:27 +00:00
|
|
|
( cat << EOF
|
2003-12-06 16:29:21 +00:00
|
|
|
# fluxbox startup-script:
|
|
|
|
#
|
|
|
|
# Lines starting with a '#' are ignored.
|
|
|
|
|
|
|
|
# You can set your favourite wallpaper here if you don't want
|
|
|
|
# to do it from your style.
|
|
|
|
#
|
2006-04-22 09:49:05 +00:00
|
|
|
# fbsetbg -f $HOME/pictures/wallpaper.png
|
2003-12-06 16:29:21 +00:00
|
|
|
#
|
|
|
|
# This sets a black background
|
|
|
|
|
2005-07-12 04:56:05 +00:00
|
|
|
@pkgbindir@/fbsetroot -solid black
|
2003-12-06 16:29:21 +00:00
|
|
|
|
|
|
|
# This shows the fluxbox-splash-screen
|
2005-04-27 12:52:51 +00:00
|
|
|
# fbsetbg -C @pkgdatadir@/splash.jpg
|
2003-12-06 16:29:21 +00:00
|
|
|
|
|
|
|
# Other examples. Check man xset for details.
|
|
|
|
#
|
|
|
|
# Turn off beeps:
|
|
|
|
# xset -b
|
|
|
|
#
|
|
|
|
# Increase the keyboard repeat-rate:
|
|
|
|
# xset r rate 195 35
|
|
|
|
#
|
|
|
|
# Your own fonts-dir:
|
2006-04-17 09:47:40 +00:00
|
|
|
# xset +fp "$HOME/.fonts"
|
2003-12-06 16:29:21 +00:00
|
|
|
#
|
|
|
|
# Your favourite mouse cursor:
|
|
|
|
# xsetroot -cursor_name right_ptr
|
|
|
|
#
|
|
|
|
# Change your keymap:
|
2006-04-17 09:47:40 +00:00
|
|
|
# xmodmap "$HOME/.Xmodmap"
|
2003-12-06 16:29:21 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# Applications you want to run with fluxbox.
|
|
|
|
# MAKE SURE THAT APPS THAT KEEP RUNNING HAVE AN ''&'' AT THE END.
|
|
|
|
#
|
|
|
|
# unclutter -idle 2 &
|
|
|
|
# wmnd &
|
|
|
|
# wmsmixer -w &
|
|
|
|
# idesk &
|
|
|
|
|
|
|
|
# And last but not least we start fluxbox.
|
|
|
|
# Because it is the last app you have to run it with ''exec'' before it.
|
|
|
|
|
|
|
|
exec @pkgbindir@/fluxbox
|
|
|
|
# or if you want to keep a log:
|
2006-04-17 09:47:40 +00:00
|
|
|
# exec @pkgbindir@/fluxbox -log "$HOME/.fluxbox/log"
|
2003-12-06 16:29:21 +00:00
|
|
|
EOF
|
2005-04-09 07:46:27 +00:00
|
|
|
) > "$startup"
|
2003-12-06 16:29:21 +00:00
|
|
|
fi
|
2005-03-17 00:05:50 +00:00
|
|
|
chmod 755 "$startup"
|
|
|
|
exec "$startup"
|
2003-09-07 19:51:59 +00:00
|
|
|
fi
|