1 |
On Sat, 23 Apr 2016 14:42:56 +0200, hw wrote: |
2 |
|
3 |
> > I've done this with ACLs in the past, which is why I suggested it, but |
4 |
> > it's a pain to set up if you haven't used them before. Alan's |
5 |
> > suggestion of using inotify is probably simplest. Install incrond and |
6 |
> > put something like this in a file in /etc/incron.d |
7 |
> > |
8 |
> > /shared/dir IN_CREATE,IN_MODIFY chmod g+w $# |
9 |
|
10 |
That should actually be $@/$# |
11 |
|
12 |
> PS: How about subdirectories? The users sharing the directory can |
13 |
> create and delete them as well, and files within them; yet incron |
14 |
> ignores what happens in subdirectories. |
15 |
|
16 |
That's a prpblem, maybe ACLs would be more suitable after all. |
17 |
|
18 |
> Using 'chmod -R g+w $#' isn't very appealing, and how safely does it |
19 |
> handle file names? |
20 |
|
21 |
What is unappealing about it? I've never had any problem with file names, |
22 |
but I don't use odd ones. You could quote the $@/$# just in case, |
23 |
although if there's no shell expansion taking place it shouldn't be |
24 |
necessary. |
25 |
|
26 |
|
27 |
-- |
28 |
Neil Bothwick |
29 |
|
30 |
Hyperbole is absolutely the worst mistake you can possibly make |