You are not logged in.

#1 2010-06-07 01:36:11

dfetter88
Member
Registered: 2010-06-02
Posts: 33

Default permissions?

Is there a way to modify my system's default permissions? For example, when I create a new file/directory it will automatically have my preferred permissions. I've tinkered with umask, but haven't found it to work for me... am I missing something?

Offline

#2 2010-06-07 02:01:22

cesura
Package Maintainer (PM)
From: Tallinn, Estonia
Registered: 2010-01-23
Posts: 1,867

Re: Default permissions?

Depends on how you are making a directory, for example:

mkdir -m=770 mydirectory

It's probably not a good idea to experiment with system-wide permissions

Last edited by cesura (2010-06-07 02:02:04)

Offline

#3 2010-06-07 08:11:34

Coacher
Guest

Re: Default permissions?

umask should do the trick in such cases. Discribe why you cant use it?

#4 2010-06-07 13:28:19

dfetter88
Member
Registered: 2010-06-02
Posts: 33

Re: Default permissions?

it works for simple cases souch as 'touch foo' or 'mkdir foo'... but if I for example download a file from the web via firefox, transmission, etc. it will have different permissions.

Edit: even if i create the file locally, but I do it with a application such as a text editor, it will not have the permissions i set through umask.

Last edited by dfetter88 (2010-06-07 13:29:57)

Offline

#5 2010-06-08 01:33:32

sand_man
Member
From: Australia
Registered: 2008-06-10
Posts: 2,164

Re: Default permissions?

I don't know about firefox but transmission has its own umask set in the settings.json

Last edited by sand_man (2010-06-08 01:33:46)


neutral

Offline

#6 2010-06-12 04:33:27

Ronin15
Member
Registered: 2008-12-18
Posts: 24

Re: Default permissions?

Did you try setting your umask in th specific users .bashrc file. any changes you make here will be saved. Just entering the Umask command from the bash shell will change the permissions just for that session it will go back to default after you log out.  All you should have to use is a text editor and be in the users home that you wanna change and type nano  .bashrc (i use nano) or vi .bashrc etc...... then all you should have to type is the umask value. Im pretty sure that the umask is subtracted from the the current directory permissons a umask of 022 give us the 755 that is the default. so you would type "umask  022" then save and exit . Then test it

hope this helps

Last edited by Ronin15 (2010-06-12 04:35:54)


"Once you go Arch you will never go back"

Offline

#7 2010-06-12 07:10:34

toad
Member
From: if only I knew
Registered: 2008-12-22
Posts: 1,775
Website

Re: Default permissions?

Poor man's solution:

put an alias like itsbrad212's command into your .bashrc


never trust a toad...
::Grateful ArchDonor::
::Grateful Wikipedia Donor::

Offline

Board footer

Powered by FluxBB