[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Installing files in user directories



On 22-Oct-98, 05:21 (CDT), Santiago Vila <sanvila@unex.es> wrote: 
> On Wed, 21 Oct 1998, Steve Greenland wrote:
> 
> > Here are some problems with the current "solution":
> > 1. Who said that root's home dir is /root?
> 
> The /etc/passwd file as provided by base-passwd. If you modify root's home
> dir, you break the base-passwd package, since root is a user who belong
> to the system, not to you.

Ack. You're right -- I'd never really looked at the update password
stuff. I'm not sure I approve, but I'm not sure I've a better solution
to the problem. I'll point out that "root" is a real user, in ways that
bin, news, etc. are not. It seems unlikely that we'll actually change
the root user, though. Would it be feasible to modify the update-passwd
stuff to skip root? If you'd consider accepting such a mod, I volunteer
to do the work.

> > 2. If I deleted my .profile and .bash_profile and (whatever) from
> >    ~root, that's what I wanted to do. I don't want them replaced.
> 
> I fail to see why you want to break your system in that way.

Who says it's broken just because the startup files are there? Maybe I
changed the /etc/profile. Maybe I modified bash. Maybe I sacrifice a
chicken every time I log in as root (no, that can't be it; we sacrifice
chickens to make SCSI chains work...)

> You seem to be the only one who wants to remove all your root dotfiles.
> There is an easy workaround for you: Just create empty files and they will
> not be replaced at all.

Actually, I don't want to remove by dotfiles. I just don't want a
package changing my configuration for no good reason, and without
asking.

> > 3. There way more ways for root to screw things up. This is a pretty
> >    limited fix. I suspect it's far more like for the novice user
> >    to screw up his/her .profile in vi than to rm it completely.
> 
> Well, I encountered a user that removed it completely. 

That's not my point. My point was that you solved a very rare problem in
a way that doesn't really help, and has a potential for causing a real
problem (or at least annoying a bunch of people).

> No, the conffile mechanism is *not* better in this case, because if you
> have no file, dpkg thinks that you do not want *any* file, which is not
> what one would normally want, because then we have the PATH problem, 
> that's why these dotfiles are not conffiles anymore.

Yes, that's right. I rm'd my .profile, and put in .bash_profile, and
didn't have a .bashrc. That's what I wanted. I don't think that that is
abnormal. I think not changing that *is* better. You disagree.

> > In either case, get rid of the .bashrc. If root wants an example,
> > there's always /etc/skel. Heck, if you want to copy dot.profile and
> > dot.bashrc to /root, no problem. Just stop screwing with the files that
> > are actually used!
> 
> Well, .bashrc is not just an example, it is now sourced by .profile :-)
> This is more a reasonable default than an example.

No, it's not, because there is no reason for it to be in .bashrc.
Instead, please put both those commands in .profile, where they belong,
and get rid of the .bashrc.

> I would be willing to modify base-files.postinst so that it install
> dotfiles for root *only* when it is not being upgraded (i.e. when creating
> the base system which is being shipped in base2_0.tgz).

I would like that. Hell, I'd settle for the postinst just *asking* if I
want to write a .profile and .bashrc (on an upgrade).

> But before that I would like to be sure that this new behaviour is
> supported by all the policy people here, and that "reinstalling base-files
> did not fix my PATH" should not be considered a bug anymore.

Obviously, I agree.

> Does the rule "reinstalling a package should be idempotent" apply to
> base-files?

If that applies, then you should *always* overwrite the .profile, right?

Otherwise, I should be able to submit a bug that says "I changed my PATH
to /nowhere/in/sight, and reinstalling base-files didn't fix it."

Whatever. I'll create the empty .bashrc and .profile and be happy.

Steve


Reply to: