Re: Re: xset command setting not sticking

2010-09-13 Thread Bob Proulx
Clive Standbridge wrote:
  #~/bin/bash
 
 Unnecessary.

That depends.  In many cases it is necessary.  (But note that it is
#! not #~.  Plus #!/bin/bash --login is my recommendation.)

  exec gnome-session
 
 That should be the only active line in .xsession
 
  3. chmod +x .xsession
 
 Unnecessary, because .xsession and .xsessionrc are sourced, not
 executed.

If the file is executable then it is executed.  If executed then the
'#!' line will have effect.  If not executable then the '#!' won't
have any effect.  If it isn't executable then it is run with the
standard shell (which effectively is /bin/sh).  Therefore depending
upon what effect you are trying to achive you will either want it to
be executable or not.  For me in almost all cases I will always want
to make it executable.

See /etc/X11/Xsession.d/50x11-common_determine-startup for the code
implementing the behavior.

You can look at this old bug for more information and pointers to
previous discussions on this topic.

  http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=250765

Bob


signature.asc
Description: Digital signature


Re: xset command setting not sticking

2010-09-09 Thread Morgan Gangwere
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Wed, 8 Sep 2010 14:59:05 -0700
Tech Geek xxx wrote:

 How is totem playing when .xinitrc is run?
 Not quite sure what you mean. This is the sequence.
 BIOS-Grub-System Boots-Systme Auto logs into GNOME-Totem Runs
 automatically (through sessions-startup script)
 
 .xinitrc file resides in my home directory /home/user/.xinitrc.


Random question... but is it actually being /run/

I'd put a zenity line in there ( zenity --info --text Run from .xinitrc )
that will wait for you to press 'ok'

The reason I ask is that, IIRC, GDM does not heed .xinitrc at all. Instead, it
runs /etc/gdm/something -- making the moderately logical assumption that you're
not doing something awkward.

IF you need something that pays attention to ~/.xsession and ~/.xinitrc, you
may want to look into xdm or SLiM. I'm not sure if either does autologin, but
its worth a shot.

Just a thought...

- -- 
Morgan Gangwere
Key ID A8B6F243, available from MIT.
BOFH excuse #378:

Operators killed by year 2000 bug bite.
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.10 (GNU/Linux)

iQIcBAEBAgAGBQJMiH99AAoJEEURiCSotvJD9sQP/18Vbk7/iurzwAQdRb+cPeQU
r2LAOBoqxU+LekeSusj0MCwRMVNnkGayNn+BRLAN1/AXLeRdgtXYHXPM/v7xjHCm
lss0Cr3o6vhNM0aX3OZ7GQzK8W8nhElD9wsEb1Y+zRh6a5gCP6z9F4FP/4hhBGzL
rQ5VO3sQ12nZsnnLZK4lHurAT8ZJh1OegsClMbOJyHg8wCdK/lM1W5lk0126FKHJ
FXOo5YowKjDKKi2/qeRRqsFP869oKkryKLidOHzyugwfEdXzV08+HlxfIrZ5OFZk
PuVWW8KWhK4dgMRv0Ra/tCzXuOW9sBCABVRx/OIpOkwkmCt5ebla8osTFU4wsOC1
rA1mx4jInZjoN6NpccoZ5R1PfO1+pfXukbzYD0gVo3QWVrO9DuW6AxWo2UOZHyV+
o/RasF0MdMSugT/Kv2RvUcx3/3vCfV3l4DfpN8Rs2WXZqK7Fng0hw8bJrzxRoLM1
QpEpU2RHbTP12KWOzkfw1lIDCGSIWNQTFlBR9aSGxr0Lkh0bX8MoNBE/eThWSTHq
BM0e3wJhX2lU2JDrnAC4mMDLCTdtwLTDHDsoesxNc7TiGZbsMAcGSlGMJaaWsUbs
6XqsZoHR/5G5ltQh3cw0s7zFS92qoHIR620gMSqal9gw/vJ4xcbr8IKhTWd7EQeu
OvDqhAcCN/400Hgrd7jv
=aS1Y
-END PGP SIGNATURE-


Re: xset command setting not sticking

2010-09-09 Thread Tech Geek
I'd put a zenity line in there ( zenity --info --text Run from .xinitrc )
that will wait for you to press 'ok'
I tried it. I do get the dialog box but after clicking OK I get the dialog
saying:
Your last session only lasted for less than 10 seconds. If you have not
logged out yourself, this could mean that there is some installation problem
or that you may be out of diskspace. Try logging in with one of the failsafe
sessions to see if you can fix this problem.

and then it logs me out to the GDM login screen again.

Upon viewing .xsesson-errors file I see just one line:

/etc/gdm/Xsession: Beginning session setup...

Please not that I entered the zenity command in .xinitrc file and then I
did:

ln -s .xinitrc .xsession

in order to make GDM read the file. It seems that GDM honors .xsession file
and not .xinitrc [1].

Also at this point no matter what command I give in .xsession (basically
.xinitrc) I do get the Your last session... message and the system logs
out. It seems that GDM is trying out to log out of GNOME as soon as
processes the .xsession file.

Not sure what's wrong here...

[1] https://wiki.ubuntu.com/CustomXSession#Sample%20~/.xinitrc%20File


Re: xset command setting not sticking

2010-09-09 Thread Tech Geek
OK after doing some more research I found the answer.

1. nano .xsession

2. Add contents:
#~/bin/bash
xset s off -dpms 
exec gnome-session

3. chmod +x .xsession

4. Make sure the session Xclient is selected in GDM.

That's it!


Re: Re: xset command setting not sticking

2010-09-09 Thread Clive Standbridge
You should be able to make this work for any session selected in gdm
(or other display manager), and for sessions started with startx.

 OK after doing some more research I found the answer.
  
 1. nano .xsession
  
 2. Add contents:
 #~/bin/bash

Unnecessary.

 xset s off -dpms 

Move that line to .xsessionrc (along with anything else you want to
start in every X session).

 exec gnome-session

That should be the only active line in .xsession

 3. chmod +x .xsession

Unnecessary, because .xsession and .xsessionrc are sourced, not
executed.

 4. Make sure the session Xclient is selected in GDM.

Now you should be able to use any client in GDM.
But please note I don't have gdm installed to test this; I use wdm. 


-- 
Cheers,
Clive


-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/20100909212756.ga24...@rimmer.esmertec.com



xset command setting not sticking

2010-09-08 Thread Tech Geek
Hi,

I am using Debian Lenny on x86 machine. I need to make the following command
permanent upon every boot:

xset s off -dpms

I am booting into GNOME with GDM.

I have tried adding this to my /home/user/.xinitrc file:
#!/bin/bash
xset s off -dpms

and made it executable:
chmod +x .xinitrc

but it is not able to retain the setting.

Thanks.


Re: xset command setting not sticking

2010-09-08 Thread Timo Juhani Lindfors
Tech Geek techgeek12...@gmail.com writes:
 I have tried adding this to my /home/user/.xinitrc file:
 #!/bin/bash
 xset s off -dpms

 and made it executable:
 chmod +x .xinitrc

 but it is not able to retain the setting.

Is xset the only X client when it is run? Xorg resets its state when
the last client connects...


-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/84bp88gcyq@sauna.l.org



Re: xset command setting not sticking

2010-09-08 Thread Kevin Ross

 On 09/08/2010 02:02 PM, Tech Geek wrote:

Hi,
I am using Debian Lenny on x86 machine. I need to make the following 
command permanent upon every boot:

xset s off -dpms
I am booting into GNOME with GDM.
I have tried adding this to my /home/user/.xinitrc file:
#!/bin/bash
xset s off -dpms
and made it executable:
chmod +x .xinitrc
but it is not able to retain the setting.
Thanks.


You will probably want to remove gnome-power-manager from your gnome 
session.  It will turn the monitor back on, ignoring what you set with xset.



--
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org

Archive: http://lists.debian.org/4c87fcc7.7080...@familyross.net



Re: xset command setting not sticking

2010-09-08 Thread Tech Geek
 Is xset the only X client when it is run? Xorg resets its state when
the last client connects...
The only other active' program running is the totem player playing a .avi
file. No network/ethernet cable is attached to the system.

Also I forgot to mention that I am auto-logging into GNOME but that probably
should not matter.


Re: xset command setting not sticking

2010-09-08 Thread Timo Juhani Lindfors
Tech Geek techgeek12...@gmail.com writes:
 The only other active' program running is the totem player playing a .avi
 file. No network/ethernet cable is attached to the system.

How is totem playing when .xinitrc is run?


-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/847hivhpxs@sauna.l.org



Re: xset command setting not sticking

2010-09-08 Thread Tech Geek
How is totem playing when .xinitrc is run?
Not quite sure what you mean. This is the sequence.
BIOS-Grub-System Boots-Systme Auto logs into GNOME-Totem Runs
automatically (through sessions-startup script)

.xinitrc file resides in my home directory /home/user/.xinitrc.