Bug#838539: apt-get gives confusing error message when -P or --build-profile is used with unknown operation
Package: apt
Version: 1.3
Severity: normal
If you do:
apt-get build-depends -P stage1 android-platform-system-core
you get:
E: Command line option 'P' [from -P] is not understood in combination with the other options.
If you do:
apt-get --build-profiles=stage1 build-depends android-platform-system-core
you get:
E: Command line option --build-profiles=stage1 is not understood in combination with the other options
If you do:
apt-get -o Apt::Build-Profiles=stage1 build-depends android-platform-system-core
you get:
E: Invalid operation build-depends
In all three cases the issue is actually misspelling 'build-dep' as
'build-depends'. But only in the 3rd case does the user get an
indication of this. In the other two they are led to think that there
is something wrong with the -P/--build-profile option, when it is in
fact fine.
Can the parsing be fixed to give the same error in all three cases? Or
is there some good reason for this rather confusing behaviour?
If 'build-dep' is spelled correctly then all 3 flavours work as expected.
--
Wookey
Reply to: