You are not logged in.

#1 2020-06-04 05:54:33

altaway
Member
Registered: 2020-06-04
Posts: 15

[solved] move xorg.conf (system wide) to xinitrc (user specific)

I want to do this so that I can put it in my dotfiles. The wiki (both Xorg and Archlinux) suggests it is possible, but can someone specify how to do it exactly?

Last edited by altaway (2020-10-03 05:38:33)

Offline

#2 2020-06-04 08:15:48

Awebb
Member
Registered: 2010-05-06
Posts: 6,285

Re: [solved] move xorg.conf (system wide) to xinitrc (user specific)

Link to the suggestion, plz.

Offline

#3 2020-06-05 21:49:56

WorMzy
Forum Moderator
From: Scotland
Registered: 2010-06-16
Posts: 11,844
Website

Re: [solved] move xorg.conf (system wide) to xinitrc (user specific)

Mod note: moving to NC.


Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD

Making lemonade from lemons since 2015.

Offline

#4 2020-06-06 09:35:09

Mr.Elendig
#archlinux@freenode channel op
From: The intertubes
Registered: 2004-11-07
Posts: 4,092

Re: [solved] move xorg.conf (system wide) to xinitrc (user specific)

It's not possible (also you should use xorg.conf.d instead of xorg.conf)

You can set things like monitor/keyboard configuration per user, but that is not a direct replacement for setting it system wide in xorg.conf.d


Evil #archlinux@libera.chat channel op and general support dude.
. files on github, Screenshots, Random pics and the rest

Offline

#5 2020-06-06 14:18:51

adamss
Member
Registered: 2020-06-06
Posts: 20

Re: [solved] move xorg.conf (system wide) to xinitrc (user specific)

My first answer here, so glad to be part of this community

ok so the path for:
- xinitrc (system wide) is `/etc/xinitrc`
- xinitrc (user specific) is `~/.xinitrc`

`xinit` and/or `startx` are going to run the commands specified in `xinitrc` once the `X` session starts, usually to launch your favorite WM or DE, this is a user specific choice so it make sense to have a user specific configuration file for that

now the path for:
- xorg.conf (system wide) is `/etc/X11/xorg.conf` or `etc/xorg.conf`
- xorg.conf (user specific): well.. there is no such a thing

`xorg.conf` configure `X` to recognize and behave properly with your hardware drivers.

..it's not like, users are gonna switch hardware each time they login hmm
so there is no reason to have user specific configuration for that

if for some unimaginable reason you need to have this per user behavior you can use commands like `xrandr` and `xinput` to modify some of X's behavior at runtime (this mean you can put this on a user specific `xinitrc`)

it would me more helpful for me and you to provide informations on what's your need for that

TLDR;
you can't move xorg.conf to xinitrc coz they have different purpose and there is no user specific xorg.conf coz you won't need that by almost any stretch of imagination

I think you confuse xorg.conf and xinitrc

Last edited by adamss (2020-06-06 19:22:14)

Offline

#6 2020-06-07 08:10:05

adamss
Member
Registered: 2020-06-06
Posts: 20

Re: [solved] move xorg.conf (system wide) to xinitrc (user specific)

Please prepend "[SOLVED]" to the title

Offline

#7 2020-06-07 08:38:04

seth
Member
Registered: 2012-09-03
Posts: 50,983

Re: [solved] move xorg.conf (system wide) to xinitrc (user specific)

@adamss, the OP has so far not responded at all and esp. not elaborated on "The wiki (both Xorg and Archlinux) suggests it is possible". Ie. so far we're at best speculating what he actually tries to do and the answers to an assumed question can only ever be assumed solutions.
(What is for sure is that the question, as presented, makes little to no sense at all - as you and pointed out: xinitrc and xorg.conf are fundamentally different things)

Ftr.: Xorg knows "-config" and "-configdir" to provide custom config files and the Xorg config provides more than a representation of the available HW (which should be left to autodetection anyway) - notably screen layouts for zaphod or multi-GPU setups.

Offline

#8 2020-06-09 12:27:14

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 29,522
Website

Re: [solved] move xorg.conf (system wide) to xinitrc (user specific)

seth wrote:

Ftr.: Xorg knows "-config" and "-configdir" to provide custom config files ...

Yes, but these are fairly limited if Xorg is run as a non-root user (which is default in arch).  These flags can only specify files / directories under the hardwired system locations.

It would be easy to use /etc/X11/$USER in as a replacement for xorg.conf or xorg.conf.d, but one could not use anything like ~/.xorg.conf.d unless they were running xorg as root. And if running as root, it'd have to explicitly be specified as /home/username/.xorg.conf.d (as "~" would not refer to the intended user's home directory).


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Offline

#9 2020-06-09 12:59:43

seth
Member
Registered: 2012-09-03
Posts: 50,983

Re: [solved] move xorg.conf (system wide) to xinitrc (user specific)

Well, "default" for non-nvidia xinit (and apparently now also GDM) users (which I assume you'll overestimate ;-), but yes.
Rootless X11 using ~/.xorg.conf would eg. require a hardlink to /etc/X11/something (not sure at hand whether you'd get away w/ an xorg.conf.d symlink)

Offline

#10 2020-06-09 13:11:20

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 29,522
Website

Re: [solved] move xorg.conf (system wide) to xinitrc (user specific)

Perhaps I overestimate - but I estimate based on the wiki which says that gdm runs xorg rootless, and there is no specific mention of exception in the xorg page of needing to run Xorg as root in the nvidia page.


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Offline

#11 2020-06-09 13:27:24

seth
Member
Registered: 2012-09-03
Posts: 50,983

Re: [solved] move xorg.conf (system wide) to xinitrc (user specific)

Xorg wiki wrote:

If using certain proprietary display drivers, kernel mode setting auto-detection will fail. In such cases, you must set needs_root_rights = no in /etc/X11/Xwrapper.config.

Looking at the process list on a 390xx nvidia system w/o Xwrapper.config, Xorg currently runs as root. I could try to force it and see whether that works at all.

Offline

Board footer

Powered by FluxBB