You are not logged in.

#1 2009-01-28 07:47:21

tjwoosta
Member
Registered: 2008-12-18
Posts: 453

any way to use same Desktop, Pictures, etc.. folders for all users ?

so i have this crazy idea of installing a bunch of window managers all on the same arch installation

i can't do it all with ony one user because there are config files in every users home dir that need to be different for different themes etc..


so now that i have three different users, each with a seperate WM, i have noticed one giant flaw in my plan

i need to find a way to use the same Desktop, Pictures, Music, Videos, and Documents folders for all three users

does anybody have any ideas?

Offline

#2 2009-01-28 08:04:28

Runiq
Member
From: Germany
Registered: 2008-10-29
Posts: 1,053

Re: any way to use same Desktop, Pictures, etc.. folders for all users ?

Should work with symlinks (maybe even hardlinks? Someone more knowledgeable please elaborate on that) and the right permissions.

For the permission thing, add your users to a newly-created group, change the group of your Desktop, Pictures, etc. folders to this one and set proper rwx permissions for it.

Offline

#3 2009-01-28 14:42:40

u_no_hu
Member
Registered: 2008-06-15
Posts: 453

Re: any way to use same Desktop, Pictures, etc.. folders for all users ?

/etc/skel ? 

(Edit: I read it wrong  smile )

Last edited by u_no_hu (2009-01-28 14:44:20)


Don't be a HELP VAMPIRE. Please search before you ask.

Subscribe to The Arch Daily News.

Offline

#4 2009-01-28 21:37:32

Diaz
Member
From: Portugal
Registered: 2008-04-16
Posts: 366

Re: any way to use same Desktop, Pictures, etc.. folders for all users ?

i am with the same interest, i have 3 normal users to test different wms (one for gnome, other kde and openbox), and one another folder in home with the name "all". there i have folders like music, images, downloads. Symliked them to the normal users folders, but permissions are a little strange. i tried to get them so everybody could rwx all folders and files like if they where the owners. I can get it if i already have files there and change the permissions, but with newly created files the permissions get messed up again...


if anyone got it right it would be apreciated.

Offline

#5 2009-01-29 02:52:20

kludge
Member
Registered: 2008-08-03
Posts: 294

Re: any way to use same Desktop, Pictures, etc.. folders for all users ?

i do belive that this is exactly what /usr/share is for.

from the The Filesystem Hierarchy Standard

/usr is the second major section of the filesystem. /usr is shareable, read-only data. That means that /usr should be shareable between various FHS-compliant hosts and must not be written to. Any information that is host-specific or varies with time is stored elsewhere.
<snip />
share    Architecture-independent data
<snip />
/usr/local/share

The requirements for the contents of this directory are the same as /usr/share. The only additional constraint is that /usr/local/share/man and /usr/local/man directories must be synonomous (usually this means that one of them must be a symbolic link).

that's on a distro where the distro provides everything in the main hierarchy.  theoretically, stuff provided by the sysadmin (as opposed to the distro maintainers) would go in /usr/local/share.  but as with lfs or gentoo, the sysadmin of an arch box essentially is the distribution (unless you never customize *any* of your configs).  so go ahead with putting all this stuff in one of those places.

EDIT: i *also* read this a bit wrong.  that would work well for you desktops.  for all the rest, you could create a /media_files tree that's world readable, or that is mounted with --bind each time a user logs in.

Last edited by kludge (2009-01-29 02:57:37)


[23:00:16]    dr_kludge | i want to invent an olfactory human-computer interface, integrate it into the web standards, then produce my own forked browser.
[23:00:32]    dr_kludge | can you guess what i'd call it?
[23:01:16]    dr_kludge | nosilla.
[23:01:32]    dr_kludge | i really should be going to bed.  i'm giggling madly about that.

Offline

#6 2009-01-29 09:25:11

evilgold
Member
Registered: 2008-10-30
Posts: 120

Re: any way to use same Desktop, Pictures, etc.. folders for all users ?

Yes its possible. You just need to link one users folders to the other 2. for example

ln -s /home/user1/Desktop /home/user2/Desktop

if you want to keep things like firefox settings or other programs you'll need to link most of the hidden folders as well. a few exceptions like .Xsession, .xinitrc, and .dmrc you wont want to link.

Offline

#7 2009-01-31 03:29:19

tjwoosta
Member
Registered: 2008-12-18
Posts: 453

Re: any way to use same Desktop, Pictures, etc.. folders for all users ?

evilgold wrote:

Yes its possible. You just need to link one users folders to the other 2. for example

ln -s /home/user1/Desktop /home/user2/Desktop

if you want to keep things like firefox settings or other programs you'll need to link most of the hidden folders as well. a few exceptions like .Xsession, .xinitrc, and .dmrc you wont want to link.

when i try this command it just makes a file on user2's Desktop called "Desktop" and if i click on it, it asks me what application i want to use to run it

what am i doing wrong?

Offline

#8 2009-01-31 07:11:13

.:B:.
Forum Fellow
Registered: 2006-11-26
Posts: 5,819
Website

Re: any way to use same Desktop, Pictures, etc.. folders for all users ?

evilgold wrote:

Yes its possible. You just need to link one users folders to the other 2. for example

ln -s /home/user1/Desktop /home/user2/Desktop

That would be nice - if it worked. You don't have the necessary permissions to access that stuff because it belongs to a different user.

A filthy solution would be to use mount with the bind option for the subfolders you want shared (and at least readable to the users group). But, as said before, /usr/share is there for things like these, so I'd go with that; it's the cleanest solution in the long run.


Got Leenucks? :: Arch: Power in simplicity :: Get Counted! Registered Linux User #392717 :: Blog thingy

Offline

#9 2009-01-31 07:59:39

robertp
Member
From: Warszawa, Poland
Registered: 2007-09-11
Posts: 123

Re: any way to use same Desktop, Pictures, etc.. folders for all users ?

You should create one separate directory with subdirectories for Desktop, Pictures, Music, Videos, and Documents. For example /home/common. I currently have /data on separate partitition.
Then create a group:

group commondata

and add the three users to this group:

gpasswd -a user commondata

Then

chown -R user.commondata /home/common
chmod -R g=u /home/common

After this all three users should have access to files in /home/common.

The last thing to do is to create symbolic links to Desktop and others.

@B, @kludge: /usr/share is a fatal place to put such files unless you are not afraid to lose them after reinstall.

Last edited by robertp (2009-01-31 08:02:06)

Offline

#10 2009-01-31 14:26:07

Inxsible
Forum Fellow
From: Chicago
Registered: 2008-06-09
Posts: 9,183

Re: any way to use same Desktop, Pictures, etc.. folders for all users ?

robertp wrote:

@B, @kludge: /usr/share is a fatal place to put such files unless you are not afraid to lose them after reinstall.

That's why creating a separate /usr partition during install helps smile . That way you can mount an existing /usr, when you re-install.

Last edited by Inxsible (2009-01-31 14:26:49)


Forum Rules

There's no such thing as a stupid question, but there sure are a lot of inquisitive idiots !

Offline

Board footer

Powered by FluxBB