Revision 24976,
509 bytes
checked in by jdreed, 14 years ago
(diff) |
In xsession:
* Don't use dpkg-query because it slows logins down; instead ship actual
scripts in /usr/share and source them (Trac #778)
|
Rev | Line | |
---|
[24976] | 1 | # This file is sourced by Xsession(5), not executed. |
---|
| 2 | |
---|
| 3 | # Work around the absence of the message function (to pretty-print user |
---|
| 4 | # messages) from some versions of gdm's Xsession script. |
---|
| 5 | if ! hash message 2>/dev/null ; then |
---|
| 6 | message () { |
---|
| 7 | text="$@" |
---|
| 8 | echo "$text" | fold -s |
---|
| 9 | if [ -n "$DISPLAY" ]; then |
---|
| 10 | if hash zenity 2>/dev/null ; then |
---|
| 11 | zenity --info --text "$text" |
---|
| 12 | elif hash xmessage 2>/dev/null ; then |
---|
| 13 | echo "$text" | fold -s | xmessage -center -file - |
---|
| 14 | fi |
---|
| 15 | fi |
---|
| 16 | } |
---|
| 17 | fi |
---|
Note: See
TracBrowser
for help on using the repository browser.