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 MANPATH if you use MA

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 MANPAT

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 o

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 https://guide.macports.org

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

2017-03-22 Thread Ryan Schmidt
> On Mar 22, 2017, at 05:41, Brandon Allbery wrote: > > On Wed, Mar 22, 2017 at 5:48 AM, Ryan Schmidt wrote: > 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 wil

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

2017-03-22 Thread Brandon Allbery
On Wed, Mar 22, 2017 at 5:48 AM, Ryan Schmidt wrote: > > 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 ema

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 build log, and mail i

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 sine nomine a

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 build log, and mail it

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: would

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

2017-03-21 Thread Peter West
> On 21 Mar 2017, at 11:30 pm, Jan Stary wrote: > … > The same error is there now. > After a fresh install of 2.4.1 yesterday, > 'port' is not found, because /opt/local/bin is not in my PATH. > The installer has written the PATH=... bit into my ~/.profile, > but that does not mean it is the PATH

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

2017-03-21 Thread Jan Stary
Here is a diff to postflight and an accompanying diff to installing.xml (what other places need to be touched if this goes through?) Jan diff --git a/portmgr/dmg/postflight.in b/portmgr/dmg/postflight.in index 750553f0..a3a8bd80 100755 --- a/portmgr/dmg/postflight.in +++ b/portmgr/dmg/po

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

2017-03-21 Thread Brandon Allbery
On Tue, Mar 21, 2017 at 11:29 AM, Daniel J. Luke wrote: > While I agree with you in principle (see list archives where I disagreed > with adding this to the installer way back when it was first introduced) - > Ryan is right that we used to get lots of support requests where people > apparently we

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 back when it was f

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

2017-03-21 Thread Jan Stary
On Jan 28 16:31:12, ba...@barrys-emacs.org wrote: > 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. On Feb 01 00:38:03, ryandes...@macports.org wrote: > > Nothing should change my .bash_profile wi

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

2017-02-05 Thread Barry Scott
> On 5 Feb 2017, at 16:30, Bachsau wrote: > > 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

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 ch

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

2017-02-05 Thread Barry Scott
> On 4 Feb 2017, at 18:53, Brandon Allbery wrote: > > 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 >

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

2017-02-04 Thread Eneko Gotzon
On Sat, Feb 4, 2017 at 9:35 PM, Bachsau wrote: > Over the years of working with Linux… ​I understand, I accept but, if possible, keep in mind that there also are MacPorts users​ being no more than (humble) computer users. ​This is not a request but only an indication. ​Thank all you for all y

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

2017-02-04 Thread Bachsau
Am 04.02.2017 um 17:31 schrieb Eneko Gotzon: Rather, ​at least in my case, the​ is ​s ue ​is ​ to not having enough time to learn. I never sat down to learn anything but Python 3 explicitly. Over the years of working with Linux knowledge came on its own. smime.p7s Description: S/MIME Crypt

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 thinking of /etc/paths.d > >

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 toward making MacPorts eas

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 bug anymore. > > Not

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 mailto:w...@bachsau.name>> 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 hopef

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 anymore. > > Not o

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 in

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” se

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 s

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 USHELL,

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 not support the “sh” shel

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 postinstall is running in is a >

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 de

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

2017-01-29 Thread Ryan Schmidt
On Jan 28, 2017, at 10:31, Barry Scott wrote: > 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? No. > So far I have 3 sets of the

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 is

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 reinstall MacPorts. I

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}' Supporte

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 been using the .pkg to reins

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. > > (ie if you upgrade usin

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 Jan 2017, at 16:37, Chris

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

2017-01-28 Thread Barry
> On 28 Jan 2017, at 16:37, Christopher Jones wrote: > > Hi, > > It would be better yet if whatever it is that does this first checks to see > in the path it is about to add is already in the users PATH, and does not add > it again if already there… That would be an improvement. I would als

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

2017-01-28 Thread Christopher Jones
Hi, It would be better yet if whatever it is that does this first checks to see in the path it is about to add is already in the users PATH, and does not add it again if already there… Chris > On 28 Jan 2017, at 4:31 pm, Barry Scott wrote: > > I want to be able to stop MacPorts Installation

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

2017-01-28 Thread 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 same file. Barry