You are not logged in.

#51 2016-07-07 07:08:12

johnraff
nullglob
From: Nagoya, Japan
Registered: 2015-09-09
Posts: 6,336
Website

Re: Reorganize autostart

Head_on_a_Stick wrote:

I have a radical suggestion.

How about dropping the use of the autostart script entirely and using ~/.xsession instead?

Not keen on this at all. It would disrupt the Debian startx procedure. .xsessionrc might be feasable, but I don't see any advantages to be honest.

This would make the script far more portable to other window managers and removes a confusing layer of abstraction.

I see that as a disadvantage. That openbox/autostart only applies to openbox sessions allows more flexibility IMO. Other window manager sessions will quite likely need a different set of apps. I keep a startup.sh for things that I want run with any window manager.

There is no need to add the xdg autostart line to the file as LightDM starts these anyway

Are you sure about that? Then why doesn't openbox's script result in double-icons?


...elevator in the Brain Hotel, broken down but just as well...
( a boring Japan blog (currently paused), idle Twitterings and GitStuff )

Introduction to the Bunsenlabs Lithium Desktop

Offline

#52 2016-07-07 07:10:52

johnraff
nullglob
From: Nagoya, Japan
Registered: 2015-09-09
Posts: 6,336
Website

Re: Reorganize autostart

Head_on_a_Stick wrote:
johnraff wrote:

are you using the backported tint2

No, I am not.

Indeed. I went back to the standard tint2 and it still looks good.

Last edited by johnraff (2016-07-07 07:11:43)


...elevator in the Brain Hotel, broken down but just as well...
( a boring Japan blog (currently paused), idle Twitterings and GitStuff )

Introduction to the Bunsenlabs Lithium Desktop

Offline

#53 2016-07-07 07:21:02

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 8,759
Website

Re: Reorganize autostart

johnraff wrote:

There is no need to add the xdg autostart line to the file as LightDM starts these anyway

Are you sure about that?

I use ~/.xsession in Debian jessie with LightDM on my girlfriend's laptop and the XDG stuff all works as expected.

I could be wrong though, give me a minute...

EDIT: No time, back in 12 hours...

hmm

Last edited by Head_on_a_Stick (2016-07-07 07:23:18)


“Et ignotas animum dimittit in artes.” — Ovid, Metamorphoses, VIII., 18.

Forum Rules   •   How to report a problem   •   Software that rocks

Offline

#54 2016-07-07 13:08:02

hhh
Meep!
Registered: 2015-09-17
Posts: 9,067
Website

Re: Reorganize autostart

johnraff wrote:
hhh wrote:

I'm asking why, for example, xfce4-power-manager doesn't get autostarted automatically every time.

But it does!

Well! I never noticed. We should definitely consider consolidating autostart into one location then, and I would vote for the Openbox autostart file since it can be edited per-user-session by the user..

Offline

#55 2016-07-07 13:15:05

hhh
Meep!
Registered: 2015-09-17
Posts: 9,067
Website

Re: Reorganize autostart

@HoaS, I vote we keep BL's autostart in ~/.config/openbox/openstart, for the reasons johnraff stated. With this setup, if a newbie were to install a DE onto BL, it would fire up more or less normally, whereas ~.xsessionrc might cause confusion and havoc. Or at least minor messiness.

Offline

#56 2016-07-07 13:18:33

hhh
Meep!
Registered: 2015-09-17
Posts: 9,067
Website

Re: Reorganize autostart

For running multiple stand-alone WM sessions, one could use multiple .xsessionrc files and rename them or use desktop files as I described here...
http://crunchbang.org/forums/viewtopic. … 40#p418140

Anyway, I think it would be easier to troubleshoot that issue on a case-by-case basis.

Offline

#57 2016-07-07 16:22:14

cloverskull
Member
Registered: 2015-10-01
Posts: 307

Re: Reorganize autostart

Head_on_a_Stick wrote:

How about dropping the use of the autostart script entirely and using ~/.xsession instead?

I'd prefer not to do this. Not all wm's are created equal. I'd prefer to configure each wm to be a custom tailored session with settings that completely make sense for that wm, and avoid loading up extra "cruft" that launching a different wm may incur if it doesn't use certain features of things we're trying to automatically start.

Offline

#58 2016-07-07 18:54:04

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 8,759
Website

Re: Reorganize autostart

johnraff wrote:

There is no need to add the xdg autostart line to the file as LightDM starts these anyway

Are you sure about that? Then why doesn't openbox's script result in double-icons?

I was completely wrong about this, sorry for the noise  ops

@{johnraff,hhh,cloverskull} -- fair enough, it was just a suggestion smile


“Et ignotas animum dimittit in artes.” — Ovid, Metamorphoses, VIII., 18.

Forum Rules   •   How to report a problem   •   Software that rocks

Offline

#59 2016-07-07 21:12:32

hhh
Meep!
Registered: 2015-09-17
Posts: 9,067
Website

Re: Reorganize autostart

Head_on_a_Stick wrote:

@{johnraff,hhh,cloverskull} -- fair enough, it was just a suggestion smile

We should get this out in the open right now... I don't think there is any suggestion that is "wrong", look at how much cruft we're exposing just in this thread, which I thought would last a page at most. Feel free to disagree, because that's what I'm talking about!

Put it out there. If it gets shot down, give us the Linus NVidia finger and post a bunch of monkey emojies, you'll feel better.

monkey  monkey  monkey
   monkey  monkey  monkey
monkey  monkey  monkey
   monkey  monkey  monkey
monkey  monkey  monkey

unnamed.jpg

Offline

#60 2016-07-07 21:18:48

hhh
Meep!
Registered: 2015-09-17
Posts: 9,067
Website

Re: Reorganize autostart

^ That's good comedy.

Offline

#61 2016-07-08 02:57:52

johnraff
nullglob
From: Nagoya, Japan
Registered: 2015-09-09
Posts: 6,336
Website

Re: Reorganize autostart

[HELIUM] This is a slight fork-off from openbox/autostart, and when/if I put together a proof-of-concept (or if responses to this post get out of hand) I'll start a new thread. I've been thinking for a while it might be good to have a /usr/share/xsessions/bunsenlabs.desktop with contents something like:

[Desktop Entry]
Name=BunsenLabs
Comment=Log in to a BunsenLabs Linux session
Exec=/usr/bin/startbunsenlabs
TryExec=/usr/bin/startbunsenlabs
Icon=BunsenLabs
Type=Application

An icon would appear in LightDm's menu. After looking again at startxfce4 and startlxde for inspiration, we could make a script startbunsenlabs that would possibly use a custom-configured lxsession (or something else?) to set up the user session before launching openbox. That should leave other DMs or startx unaffected.

(Alternatively, have a very simple startbunsenlabs that just does startx?)

Of course complete modularity is impossible/very_difficult because at the end of the day the user only has one ~/.config/somedir/somefile which all possible sessions have to deal with somehow.

Last edited by johnraff (2016-07-08 02:59:24)


...elevator in the Brain Hotel, broken down but just as well...
( a boring Japan blog (currently paused), idle Twitterings and GitStuff )

Introduction to the Bunsenlabs Lithium Desktop

Offline

#62 2016-07-08 05:09:52

johnraff
nullglob
From: Nagoya, Japan
Registered: 2015-09-09
Posts: 6,336
Website

Re: Reorganize autostart

hhh wrote:
johnraff wrote:
hhh wrote:

xfce4-power-manager doesn't get autostarted automatically

But it does!

We should definitely consider consolidating autostart into one location then, and I would vote for the Openbox autostart file since it can be edited per-user-session by the user..

It wouldn't be easy to eliminate /etc/xdg/autostart completely because many apps drop .desktop files there if they think they should be autostarted. Without that dir.d/* type system (very useful throughout Debian) users would have to add and remove those apps manually in openbox/autostart. Of course there are arguments for that too, but I think we should just learn to live with having the two locations.


...elevator in the Brain Hotel, broken down but just as well...
( a boring Japan blog (currently paused), idle Twitterings and GitStuff )

Introduction to the Bunsenlabs Lithium Desktop

Offline

#63 2016-07-08 05:30:04

cloverskull
Member
Registered: 2015-10-01
Posts: 307

Re: Reorganize autostart

Would this prevent multi-user setups with multiple different dotfile configs? Would this introduce issues with those of us that like to iterate between different de's? TBH I only ever knew about the ~/.config/ dotfiles, wasn't aware we were profiling ones in /etc/xdg/ smile

Offline

#64 2016-07-08 06:01:59

johnraff
nullglob
From: Nagoya, Japan
Registered: 2015-09-09
Posts: 6,336
Website

Re: Reorganize autostart

cloverskull wrote:

Would this prevent multi-user setups with multiple different dotfile configs?

This has been part of the Debian system for a long time - it's not something we are doing specifically. All DEs are expected to execute the desktop files in /etc/xdg/autostart (depending on the OnlyShowIn and NotShowIn lines).

Individual user configuration of the xdg autostarted apps is possible by copying .desktop files from /etc/xdg/autostart to ~/.config/autostart and editing them there.


...elevator in the Brain Hotel, broken down but just as well...
( a boring Japan blog (currently paused), idle Twitterings and GitStuff )

Introduction to the Bunsenlabs Lithium Desktop

Offline

#65 2016-07-08 06:17:14

johnraff
nullglob
From: Nagoya, Japan
Registered: 2015-09-09
Posts: 6,336
Website

Re: Reorganize autostart

Back to topic: @hhh I've taken your original suggested autostart and modified it according to input from @HoaS and my own thoughts. My current autostart looks a lot like this and seems to be causing no problems, but that doesn't mean there are none.

Nearly all the sleeps are gone, along with most of the ampersands. (I'm now wondering if some of the compositing/systray weirdness we had in the past might have been caused by the very race conditions @HoaS referred to with forking.)

@hhh contributed a couple of extra keyboard & touchpad settings.

The exact order of commands is more important now, without forking, and might well need tweaking. My personal file starts compton before tint2 while @hhh has tint2 first (as here). I've moved nitrogen earlier than @hhh had it, for no particular reason...

Any opinions on which commands should run before/after others, along with whether any other delays are needed, will be gratefully entertained. smile

## SETTINGS START

## Turn on/off system beep.
xset b off

## Set keyboard settings - 250 ms delay and 25 cps (characters per second) repeat rate.
## Adjust the values according to your preferances.
xset r rate 250 25

## Add keyboard mapping.
#xmodmap -e "keysym Insert = Multi_key"

## NEW
## Disable CapsLK
setxkbmap -option ctrl:nocaps

## Configure touchpad. See 'man synaptics' for more info.
synclient VertEdgeScroll=1 HorizEdgeScroll=1 TapButton1=1 2>/dev/null

## NEW
## Disable touchpad while typing
syndaemon -i .5 -K -t -R -d &

## SETTINGS END

## GNOME PolicyKit authentication
/usr/lib/policykit-1-gnome/polkit-gnome-authentication-agent-1 &

## Set a wallpaper
nitrogen --restore

## Start the tint2 session (the default tint2 will run if no sessions have been set)
bl-tint2-session

## Compton
bl-compositor --start

## Start the Conky session (the default conkyrc will run if no sessions have been set)
bl-conky-session --autostart &

## Start the battery applet
fdpowermon &

## Volume control for systray
(sleep 12; volumeicon) &
## Replace with this?:
#pnmixer &

## Start Clipboard manager
clipit &

## bl-welcome - post-installation script, will not run in a live session and
## only runs once. Safe to remove.
(sleep 10; bl-welcome --firstrun) &

## DISABLED

## Volume keys daemon (probably not needed)
#xfce4-volumed &

## Start xscreensaver (light-locker now used by default, run via XDG autostart.)
#xscreensaver -no-splash &

## bl-fortune - have the system come up with a little adage (not yet enabled)
#(sleep 120; bl-fortune) &

...elevator in the Brain Hotel, broken down but just as well...
( a boring Japan blog (currently paused), idle Twitterings and GitStuff )

Introduction to the Bunsenlabs Lithium Desktop

Offline

#66 2016-07-08 06:56:18

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 8,759
Website

Re: Reorganize autostart

^ Good work smile

I will try this out on my system tonight.

Does your system really need 12 seconds for volumeicon?
yikes

There must be something going on here, I have used volumeicon for several years in both Debian and Arch with tint2 and other panels and I have *never* had to use any `sleep` commands in ~/.{xinitrc,xession}


“Et ignotas animum dimittit in artes.” — Ovid, Metamorphoses, VIII., 18.

Forum Rules   •   How to report a problem   •   Software that rocks

Offline

#67 2016-07-08 09:51:27

johnraff
nullglob
From: Nagoya, Japan
Registered: 2015-09-09
Posts: 6,336
Website

Re: Reorganize autostart

Head_on_a_Stick wrote:

Does your system really need 12 seconds for volumeicon?

There must be something going on here, I have used volumeicon for several years in both Debian and Arch with tint2 and other panels and I have *never* had to use any `sleep` commands in ~/.{xinitrc,xession}

Were you using it with PulseAudio? The error message that appears in ~/.Xsession-errors refers to the pulse server. I started out with 2 seconds but found volumeicon failing to load on occasions. Gradually increasing the sleep - 10s seemed to be OK, but a couple of days later there it was again - now with 12s volumeicon loads every time, so far...

Actually, with pnmixer now in Stretch, a Jessie backport of that is starting to look like an attractive option. I'm currently using the Ubuntu package that @hhh posted and it's working very well.


...elevator in the Brain Hotel, broken down but just as well...
( a boring Japan blog (currently paused), idle Twitterings and GitStuff )

Introduction to the Bunsenlabs Lithium Desktop

Offline

#68 2016-07-08 12:13:11

damo
....moderator....
Registered: 2015-08-20
Posts: 5,582

Re: Reorganize autostart

Tried the autostart from https://forums.bunsenlabs.org/viewtopic … 741#p31741, with a couple of changes:

## Enable power management
xfce4-power-manager &

## Start the battery applet
# line commented due to dist-upgrade
######(sleep 2; fdpowermon) &

and

## Volume control for systray
(sleep 4; volumeicon) &

Sound control is better than with volti on this laptop - headphone/speaker switching is automatic, and mute for each is independant, and persist between log-ins.


Be Excellent to Each Other...
The Bunsenlabs Lithium Desktop » Here
FORUM RULES and posting guidelines «» Help page for forum post formatting
Artwork on DeviantArt  «» BunsenLabs on DeviantArt

Online

#69 2016-07-08 12:37:08

hhh
Meep!
Registered: 2015-09-17
Posts: 9,067
Website

Re: Reorganize autostart

@johnraff, wonderful. BTW, I've had nitrogen at the beginning of my autostart for the last week with no problems.

Agreed to 2 locations, I realized this was unavoidable right after posting.

https://specifications.freedesktop.org/ … atest.html

@cloverskull, see the link above. You can override any /etc/xdg/autostart *.desktop file locally by copying it to ~/.config/autostart and adding the following to it...

Hidden=true

Offline

#70 2016-07-08 19:46:39

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 8,759
Website

Re: Reorganize autostart

johnraff wrote:

Were you using it with PulseAudio?

Erm, no.
ops

We could try starting Pulseaudio manually using this line in autostart:

pulseaudio --start && volumeicon &

Then disable the XDG autostart.

Give me a moment to check this...


“Et ignotas animum dimittit in artes.” — Ovid, Metamorphoses, VIII., 18.

Forum Rules   •   How to report a problem   •   Software that rocks

Offline

#71 2016-07-08 19:55:27

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 8,759
Website

Re: Reorganize autostart

Head_on_a_Stick wrote:

We could try starting Pulseaudio manually using this line in autostart:

pulseaudio --start && volumeicon &

Then disable the XDG autostart.

This works for me!

smile

Can somebody else test this please?

To disable the XDG autostart, copy the .desktop file to $HOME:

mkdir -p ~/.config/autostart && cp /etc/xdg/autostart/pulseaudio.desktop ~/.config/autostart

Then add this line:

echo "Hidden=true" >> ~/.config/autostart/pulseaudio.desktop

Finally, replace the "volumeicon" line in ~/.config/openbox/autostart with the line given at the top of the post.

Thanks!


“Et ignotas animum dimittit in artes.” — Ovid, Metamorphoses, VIII., 18.

Forum Rules   •   How to report a problem   •   Software that rocks

Offline

#72 2016-07-09 03:42:08

johnraff
nullglob
From: Nagoya, Japan
Registered: 2015-09-09
Posts: 6,336
Website

Re: Reorganize autostart

Head_on_a_Stick wrote:

We could try starting Pulseaudio manually using this line in autostart:

pulseaudio --start && volumeicon &

Then disable the XDG autostart.

Interesting! This would allow us to use the vanilla volumeicon. cool

I'll test it out as soon as I've finished testing your rebuilt volumeicon...

Last edited by johnraff (2016-07-09 03:43:00)


...elevator in the Brain Hotel, broken down but just as well...
( a boring Japan blog (currently paused), idle Twitterings and GitStuff )

Introduction to the Bunsenlabs Lithium Desktop

Offline

#73 2016-07-09 05:58:33

johnraff
nullglob
From: Nagoya, Japan
Registered: 2015-09-09
Posts: 6,336
Website

Re: Reorganize autostart

(Original post was accidentally removed.)

johnraff wrote:

^It works!  cool

... It turns out they are provided by the Debian package pulseaudio-module-x11. Install it and start-pulseaudio-x11 runs without errors...

hhh wrote:

I left that package out intentionally, I remember seeing a Debian bug about a memory leak in it and it didn't seem necessary at the time. Easy enough to add it back.

Last edited by johnraff (2016-07-13 06:46:46)


...elevator in the Brain Hotel, broken down but just as well...
( a boring Japan blog (currently paused), idle Twitterings and GitStuff )

Introduction to the Bunsenlabs Lithium Desktop

Offline

#74 2016-07-10 17:02:37

hhh
Meep!
Registered: 2015-09-17
Posts: 9,067
Website

Re: Reorganize autostart

^Sorry, @johnraff, this was my post. I must have clicked Edit instead of Quote.

Offline

#75 2016-07-12 07:31:33

hhh
Meep!
Registered: 2015-09-17
Posts: 9,067
Website

Re: Reorganize autostart

johnraff wrote:

Back to topic: @hhh I've taken your original suggested autostart and modified it according to input from @HoaS and my own thoughts. My current autostart looks a lot like this and seems to be causing no problems, but that doesn't mean there are none.

Nearly all the sleeps are gone, along with most of the ampersands. (I'm now wondering if some of the compositing/systray weirdness we had in the past might have been caused by the very race conditions @HoaS referred to with forking.)

@hhh contributed a couple of extra keyboard & touchpad settings.

The exact order of commands is more important now, without forking, and might well need tweaking. My personal file starts compton before tint2 while @hhh has tint2 first (as here). I've moved nitrogen earlier than @hhh had it, for no particular reason...

Any opinions on which commands should run before/after others, along with whether any other delays are needed, will be gratefully entertained. smile

## SETTINGS START

## Turn on/off system beep.
xset b off

## Set keyboard settings - 250 ms delay and 25 cps (characters per second) repeat rate.
## Adjust the values according to your preferances.
xset r rate 250 25

## Add keyboard mapping.
#xmodmap -e "keysym Insert = Multi_key"

## NEW
## Disable CapsLK
setxkbmap -option ctrl:nocaps

## Configure touchpad. See 'man synaptics' for more info.
synclient VertEdgeScroll=1 HorizEdgeScroll=1 TapButton1=1 2>/dev/null

## NEW
## Disable touchpad while typing
syndaemon -i .5 -K -t -R -d &

## SETTINGS END

## GNOME PolicyKit authentication
/usr/lib/policykit-1-gnome/polkit-gnome-authentication-agent-1 &

## Set a wallpaper
nitrogen --restore

## Start the tint2 session (the default tint2 will run if no sessions have been set)
bl-tint2-session

## Compton
bl-compositor --start

## Start the Conky session (the default conkyrc will run if no sessions have been set)
bl-conky-session --autostart &

## Start the battery applet
fdpowermon &

## Volume control for systray
(sleep 12; volumeicon) &
## Replace with this?:
#pnmixer &

## Start Clipboard manager
clipit &

## bl-welcome - post-installation script, will not run in a live session and
## only runs once. Safe to remove.
(sleep 10; bl-welcome --firstrun) &

## DISABLED

## Volume keys daemon (probably not needed)
#xfce4-volumed &

## Start xscreensaver (light-locker now used by default, run via XDG autostart.)
#xscreensaver -no-splash &

## bl-fortune - have the system come up with a little adage (not yet enabled)
#(sleep 120; bl-fortune) &

Sorry to quote your whole post, but this is fantastic IMO. Way faster, the desktop wall is instantaneous, tint2 loads smoothly, a quick flicker for compton and then the panel applets pop up, as well as conky with it's background already transparent. Just great! BTW, I've been starting compton at the start of the file, right after nitrogen, with no issues, but where you have it is perfect. Compton seems to take a second to kick in anyway, so the timing shouldn't be that significant.

We should commit this (when our apps are finalized) for Deuterium, please!

BTW, @johnraff, we need another thread if this is possible... Any way to make updating bunsen-configs smoother? The method of deleting ~/.config/bunsen/bl-setup is kind of harsh. It wipes a bunch of non-BL settings, so to speak, including (iirc) obconf and lxappearance configs.

Offline

Board footer

Powered by FluxBB