Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 151250 - >=portage-2.1.2_pre2-r8 --tree no longer implies --pretend
Summary: >=portage-2.1.2_pre2-r8 --tree no longer implies --pretend
Status: RESOLVED INVALID
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Core - Interface (emerge) (show other bugs)
Hardware: All Linux
: High enhancement (vote)
Assignee: Portage team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-10-13 18:54 UTC by Ryan Hill (RETIRED)
Modified: 2007-02-17 20:09 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ryan Hill (RETIRED) gentoo-dev 2006-10-13 18:54:16 UTC
between portage-2.1.2_pre2-r7 and -r8 the --tree option stopped implying --pretend.  is this intended behaviour?
Comment 1 Alec Warner (RETIRED) archtester gentoo-dev Security 2006-10-13 18:56:57 UTC
Yes
Comment 2 Alec Warner (RETIRED) archtester gentoo-dev Security 2006-10-13 18:59:06 UTC
Yes, see revision 4642 

Author: zmedico
Date: 2006-10-09 21:40:32 +0000 (Mon, 09 Oct 2006)
New Revision: 4642

Modified:
   main/trunk/bin/emerge
Log:
Make --tree not imply --pretend anymore so that people can put it in EMERGE_DEFAULT_OPTS.
Comment 3 Ryan Hill (RETIRED) gentoo-dev 2006-10-13 20:53:46 UTC
(In reply to comment #2)
> Log:
> Make --tree not imply --pretend anymore so that people can put it in
> EMERGE_DEFAULT_OPTS.

not arguing, but how would implying --pretend prevent someone putting --tree in EMERGE_DEFAULT_OPTS?  the only time it actually does anything is with --pretend or --ask.  with the old behaviour you could set EMERGE_DEFAULT_OPTS="--tree" and `emerge world` would default to --pretend and could be easily switched to --ask with `emerge -a world` when you wanted to actually build the package(s).  vice versa if you did EMERGE_DEFAULT_OPTS="--tree --ask".  `emerge world` would --ask and `emerge -p world` would --pretend.

with the new behaviour, EMERGE_DEFAULT_OPTS="--tree" makes `emerge world` go straight to building (making it required to have either --pretend or --ask in the command line options for --tree to even be relevant), EMERGE_DEFAULT_OPTS="--tree --ask" is identical to the old behaviour.

so basically the changes that the new behaviour brings are:

- making --pretend or --ask required on the command line if --tree is in EMERGE_DEFAULT_OPTS
- changing the default action of --tree to not actually print a tree

i'm probably missing something glaringly obvious, but what are the benefits of this change?
Comment 4 Zac Medico gentoo-dev 2006-10-13 21:01:08 UTC
(In reply to comment #3)
> so basically the changes that the new behaviour brings are:
> 
> - making --pretend or --ask required on the command line if --tree is in
> EMERGE_DEFAULT_OPTS

They're both completely optional.  You'll only need them if you really want to see the tree display.

> - changing the default action of --tree to not actually print a tree

It does actually print a tree, as long as you've specified --ask or --pretend.
Comment 5 Zac Medico gentoo-dev 2006-10-13 21:02:51 UTC
I suppose we could make it print the tree and then continue with the merge, without either --pretend or --ask.
Comment 6 Ryan Hill (RETIRED) gentoo-dev 2006-10-13 21:34:34 UTC
(In reply to comment #4)
> > - making --pretend or --ask required on the command line if --tree is in
> > EMERGE_DEFAULT_OPTS
> 
> They're both completely optional.  You'll only need them if you really want to
> see the tree display.

true, but i would imagine someone who sets --tree as the default option wants to see the tree more often than not.  i think the default should favor the majority, and someone who specifies --tree probably expects to see a tree and might be a little confused when it doesn't work.

(In reply to comment #5)
> I suppose we could make it print the tree and then continue with the merge,
> without either --pretend or --ask.

that would be cool. :) 
Comment 7 Marius Mauch (RETIRED) gentoo-dev 2006-10-13 22:18:09 UTC
Sounds like another potential application for http://dev.gentoo.org/~genone/docs/cli-option-redesign.txt
Comment 8 Aniruddha Shankar 2007-01-22 04:51:33 UTC
Hi. I've been using --tree ever since it was in portage and it's a really useful option to me. There's absolutely no situation where I would specify displaying the tree without wanting to actually *LOOK* at the tree. --tree implying --pretend is absolutely spot on, in my opinion. 

And what's the opposite situation ? that someone would want, after, say, adding a new useflag, specify emerge -uvDNt world and NOT want to see the packages that would be merged and the dependencies pulled out as a result? 

Please revert to --tree implying --pretend
Comment 9 Ryan Hill (RETIRED) gentoo-dev 2007-01-26 22:58:09 UTC
I'd also like to mention --changelog also implies --pretend in the absence of
--ask.  I don't see any reason why their behaviour shouldn't be consistent.
Comment 10 Zac Medico gentoo-dev 2007-01-27 01:41:46 UTC
Thanks, --changelog no longer implies --pretend in svn r5790.

(In reply to comment #8)
> Please revert to --tree implying --pretend

Then people wouldn't be able to use --tree in EMERGE_DEFAULT_OPTS.
Comment 11 Ryan Hill (RETIRED) gentoo-dev 2007-01-27 02:07:22 UTC
after speaking with zmedico i'm convinced this is a Good Thing(tm).
Comment 12 Charles Stewart 2007-02-12 23:34:01 UTC
Please re-enable --tree implies --pretend.  I am tutoring many new gentoo users, and this one has been very annoying.  IMHO, I believe that I speak for many gentoo users out there in saying that this behavior has come to be expected from the emerge tool.  I would have no choice to give in to the logic for removing this behavior, but no tree output is even printed without the --pretend argument.
Comment 13 Peter Ruskin 2007-02-17 19:57:25 UTC
Please re-enable --tree implies --pretend.  If you add --tree it must mean you want to see the tree before emerging; otherwise why on earth would you add --tree?
Comment 14 Zac Medico gentoo-dev 2007-02-17 20:09:10 UTC
(In reply to comment #13)
> Please re-enable --tree implies --pretend.  If you add --tree it must mean you
> want to see the tree before emerging; otherwise why on earth would you add
> --tree?

I intend to make it display the --tree output and then continue with the merge.  See bug #166880.