Re: Prevent MacPorts editing .bash_profile over and over again...

2017-03-22 Thread Christopher Jones
> On 22 Mar 2017, at 1:32 pm, Jan Stary wrote: > > On Mar 22 12:53:15, rai...@macports.org wrote: >> On 2017-03-21 21:43, Jan Stary wrote: >>> +echo "Remember to set your environment:" >>> +echo "Prepend ${BINPATH} and ${SBINPATH} to PATH." >>> +echo "Prepend ${MANPAGES} to

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-03-22 Thread Jan Stary
On Mar 22 14:32:03, h...@stare.cz wrote: > On Mar 22 12:53:15, rai...@macports.org wrote: > > On 2017-03-21 21:43, Jan Stary wrote: > > > +echo "Remember to set your environment:" > > > +echo "Prepend ${BINPATH} and ${SBINPATH} to PATH." > > > +echo "Prepend ${MANPAGES} to MANPATH if you use

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-03-22 Thread Jan Stary
On Mar 22 12:53:15, rai...@macports.org wrote: > On 2017-03-21 21:43, Jan Stary wrote: > > +echo "Remember to set your environment:" > > +echo "Prepend ${BINPATH} and ${SBINPATH} to PATH." > > +echo "Prepend ${MANPAGES} to MANPATH if you use MANPATH." > > +echo "Remember to set DISPLAY if you are

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-03-22 Thread Rainer Müller
On 2017-03-21 21:43, Jan Stary wrote: > +echo "Remember to set your environment:" > +echo "Prepend ${BINPATH} and ${SBINPATH} to PATH." > +echo "Prepend ${MANPAGES} to MANPATH if you use MANPATH." > +echo "Remember to set DISPLAY if you are on 10.4 or older." > +echo "See

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-03-22 Thread Ryan Schmidt
On Mar 21, 2017, at 18:21, Brandon Allbery wrote: > On Tue, Mar 21, 2017 at 7:18 PM, Brandon Allbery wrote: >> vim $(port logfile thePort) > > ...and the port you installed will usually get expanded with . > (bash/zsh, in default emacs mode) so you don't even need to type that :) I'm not aware

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-03-22 Thread Ryan Schmidt
> On Mar 21, 2017, at 16:23, Dave Horsfall wrote: > > On Tue, 21 Mar 2017, Brandon Allbery wrote: > >> Never assume people will read instructions. How often do we get people >> who cut and paste the boilerplate at the end of a failed build that >> tells them to check the

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-03-22 Thread Chris Jones
On 21/03/17 20:43, Jan Stary wrote: Here is a diff to postflight and an accompanying diff to installing.xml (what other places need to be touched if this goes through?) I do not think this will get committed. At least I hope it does not. As explained by others the current situation where if

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-03-21 Thread Brandon Allbery
On Tue, Mar 21, 2017 at 7:18 PM, Brandon Allbery wrote: > vim $(port logfile thePort) > ...and the port you installed will usually get expanded with . (bash/zsh, in default emacs mode) so you don't even need to type that :) -- brandon s allbery kf8nh

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-03-21 Thread Brandon Allbery
On Tue, Mar 21, 2017 at 5:23 PM, Dave Horsfall wrote: > On Tue, 21 Mar 2017, Brandon Allbery wrote: > > Never assume people will read instructions. How often do we get people > > who cut and paste the boilerplate at the end of a failed build that > > tells them to check the

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-03-21 Thread Dave Horsfall
On Tue, 21 Mar 2017, Brandon Allbery wrote: > Never assume people will read instructions. How often do we get people > who cut and paste the boilerplate at the end of a failed build that > tells them to check the build log, and mail it here asking what they > should do? Which reminds me:

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-03-21 Thread Daniel J. Luke
On Mar 21, 2017, at 9:30 AM, Jan Stary wrote: > I appreciate you concern about being spammed with trivia. > But it's one line in ~/.profile, which is equally trivial. While I agree with you in principle (see list archives where I disagreed with adding this to the installer way

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-02-05 Thread Bachsau
Am 05.02.2017 um 12:03 schrieb Barry Scott: Editing a system wide setting would have to come with a option to disable it. Editing any setting has to come with that option. However, I never said the installer should modify /etc/paths. I just said I did it that way and if the installer would

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-02-04 Thread Brandon Allbery
On Thu, Feb 2, 2017 at 8:09 PM, Ryan Schmidt wrote: > > > It depends on the order in your /etc/paths. If I put it first, it is > first. The advantage of /etc/paths is it is applied even to the graphical > environment, not just when running a login shell. > > Oh, I was

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-02-04 Thread Eneko Gotzon
On Fri, Feb 3, 2017 at 2:09 AM, Ryan Schmidt wrote: > There are many nontechnical users… Yes…​ > they don't want to understand how MacPorts or the shell works. Rather, ​at least in my case, the​ is ​s ue ​is ​ to not having enough time to learn. > We should work

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-02-04 Thread Ryan Schmidt
> On Feb 1, 2017, at 08:20, Bachsau wrote: > > Am 01.02.2017 um 07:38 schrieb Ryan Schmidt: >> Sorry. Repeated modifications of the profile when the modifications were >> already there was a bug. It looks like a fix was committed, so hopefully >> 2.4.1 will not have this

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-02-02 Thread Chris Jones
On 01/02/17 17:23, Barry Scott wrote: On 1 Feb 2017, at 14:20, Bachsau > wrote: Am 01.02.2017 um 07:38 schrieb Ryan Schmidt: Sorry. Repeated modifications of the profile when the modifications were already there was a bug. It looks like a fix

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-02-01 Thread Eneko Gotzon
On Wed, Feb 1, 2017 at 6:23 PM, Barry Scott wrote: > I don’t think it's safe to assume all MacPorts uses are expert admins. You are right, at least on my case. -- Eneko Gotzon Ares enekogot...@gmail.com

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-02-01 Thread Dan D.
until it is fixed, a cludge is to have a profile to copy over .profile, perhaps in .profile itself. Any subsequent macports calls/activity will not add additional path info to the working .profile.

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-02-01 Thread Barry Scott
> On 1 Feb 2017, at 14:20, Bachsau wrote: > > Am 01.02.2017 um 07:38 schrieb Ryan Schmidt: >> Sorry. Repeated modifications of the profile when the modifications were >> already there was a bug. It looks like a fix was committed, so hopefully >> 2.4.1 will not have this bug

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-02-01 Thread Bachsau
Am 01.02.2017 um 07:38 schrieb Ryan Schmidt: Sorry. Repeated modifications of the profile when the modifications were already there was a bug. It looks like a fix was committed, so hopefully 2.4.1 will not have this bug anymore. Not only repeated modifications. It simply should not do that

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-01-31 Thread Ryan Schmidt
> On Jan 31, 2017, at 07:50, Bachsau wrote: > > Am 28.01.2017 um 17:31 schrieb Barry Scott: >> I want to be able to stop MacPorts Installation from editing my >> .bash_profile. >> As it happens I already set all the env var that are needed my self. >> >> Is there a “do-not-edit-bash-profile”

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-01-31 Thread Bachsau
Am 28.01.2017 um 17:31 schrieb Barry Scott: I want to be able to stop MacPorts Installation from editing my .bash_profile. As it happens I already set all the env var that are needed my self. Is there a “do-not-edit-bash-profile” settings somewhere? So far I have 3 sets of the settings in the

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-01-31 Thread Barry Scott
Here is a pull request that fixes the issue for me. https://github.com/macports/macports-base/pull/16 "Fix the detection of /opt/local/bin in user's PATH The postflight script was using the SHELL variable, which is root's shell and not

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-01-30 Thread Clemens Lang
Hi, On Mon, Jan 30, 2017 at 05:37:41PM +, Barry Scott wrote: > > On 30 Jan 2017, at 12:44, Barry Scott wrote: > > > > When I run the postinstall as me it works are intended for my > > .bash_profile. When I run via sudo it looks at root’s file and > > states tit does

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-01-30 Thread Barry Scott
> On 30 Jan 2017, at 12:44, Barry Scott wrote: > > When I run the postinstall as me it works are intended for my .bash_profile. > When I run via sudo it looks at root’s file and states tit does not support > the > “sh” shell. I suspect that the environment that

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-01-30 Thread Barry Scott
When I run the postinstall as me it works are intended for my .bash_profile. When I run via sudo it looks at root’s file and states tit does not support the “sh” shell. I suspect that the environment that postinstall is running in is a strange in some way. (I have seen Mac specific oddities when

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-01-29 Thread Clemens Lang
Hi, On Sun, Jan 29, 2017 at 09:33:04PM +, Barry wrote: > Can I run the .pkg without damaging my current MacPorts setup? Yes, unless you're at a newer version than the .pkg will install. > Its taken some effort eo have inkscape etc installed Ports will be kept as-is. Running the installer

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-01-29 Thread Barry
Can I run the .pkg without damaging my current MacPorts setup? Its taken some effort eo have inkscape etc installed Barry > On 29 Jan 2017, at 17:29, Clemens Lang wrote: > > Hi, > >> On Sun, Jan 29, 2017 at 02:13:12PM +, Barry wrote: >> I have been using the .pkg to

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-01-29 Thread Clemens Lang
Hi, On Sun, Jan 29, 2017 at 02:13:12PM +, Barry wrote: > I have been using the .pkg to reinstall MacPorts. I guess that does > not check. It does. Specifically, the check checks what your user's shell is using /usr/bin/dscl . -read "/Users/${USER}" shell | awk -F'/' '{print $NF}'

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-01-29 Thread Craig Treleaven
AIUI, the following script is run to set up the user’s environment after the installer copies in all the payload files: https://github.com/macports/macports-base/blob/master/portmgr/dmg/postflight.in#L90 Craig > On Jan 29, 2017, at 9:13 AM, Barry wrote: > > I have

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-01-29 Thread Barry
I have been using the .pkg to reinstall MacPorts. I guess that does not check. Barry Barry > On 29 Jan 2017, at 02:52, Daniel J. Luke wrote: > > I think only the pkg installers do that - and they're supposed to not edit > the $PATH if $prefix is already in there. > >

Re: Prevent MacPorts editing .bash_profile over and over again...

2017-01-28 Thread Daniel J. Luke
I think only the pkg installers do that - and they're supposed to not edit the $PATH if $prefix is already in there. (ie if you upgrade using `port selfupdate` I don't think you have that problem). Or am I mistaken? > On Jan 28, 2017, at 4:56 PM, Barry wrote: >> On 28