Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 334721 - emerge shortest unique abbreviation commands don't work right
Summary: emerge shortest unique abbreviation commands don't work right
Status: CONFIRMED
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Core - Interface (emerge) (show other bugs)
Hardware: AMD64 Linux
: High minor (vote)
Assignee: Portage team
URL:
Whiteboard:
Keywords:
: 336333 (view as bug list)
Depends on:
Blocks:
 
Reported: 2010-08-27 02:32 UTC by Chris Reffett (RETIRED)
Modified: 2022-10-20 02:43 UTC (History)
1 user (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 Chris Reffett (RETIRED) gentoo-dev Security 2010-08-27 02:32:07 UTC
emerge seems to accept certain arguments with the shortest unique form of the command. That is, emerge --sy is equivalent to emerge --sync. However, this seems to break with other commands, as when I type "emerge -auDN world --keep" I receive "emerge: error: --keep-going option requires an argument," which is incorrect behavior. The same behavior applies to "emerge -auN --dee world," which returns "emerge: error: Invalid --deep parameter: 'world'".

Reproducibility: every time, spanning x86 and amd64 systems, both with the latest stable and testing portage versions.

Steps to reproduce:
1. Run an emerge command with at least one of the arguments shortened as described above.

Expected result:
The emerge runs normally, as if the commands had been typed out in full

Actual result:
The emerge does not run, and returns an unexpected error.

emerge --info:
Portage 2.2_rc69 (default/linux/amd64/10.0, gcc-4.4.4, glibc-2.12.1-r1, 2.6.35-tuxonice-flamethrower x86_64)
=================================================================
System uname: Linux-2.6.35-tuxonice-flamethrower-x86_64-AMD_Turion-tm-_64_X2_Mobile_Technology_TL-60-with-gentoo-2.0.1
Timestamp of tree: Fri, 27 Aug 2010 01:15:02 +0000
app-shells/bash:     4.1_p7
dev-java/java-config: 2.1.11
dev-lang/python:     2.6.5-r3, 3.1.2-r4
dev-util/cmake:      2.8.1-r2
sys-apps/baselayout: 2.0.1
sys-apps/openrc:     0.6.2
sys-apps/sandbox:    2.3-r1
sys-devel/autoconf:  2.13, 2.65-r1
sys-devel/automake:  1.8.5-r4, 1.9.6-r3, 1.10.3, 1.11.1
sys-devel/binutils:  2.20.1-r1
sys-devel/gcc:       4.4.4-r1
sys-devel/gcc-config: 1.4.1
sys-devel/libtool:   2.2.10
sys-devel/make:      3.81-r2
virtual/os-headers:  2.6.35 (sys-kernel/linux-headers)
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="* -@EULA AdobeFlash-10.1 Broadcom skype-eula Q3AEULA dlj-1.1 googleearth"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -march=k8-sse3 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/X11/xkb /usr/share/config /var/lib/hsqldb"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/portage /etc/revdep-rebuild /etc/sandbox.d /etc/splash /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-O2 -march=k8-sse3 -pipe"
DISTDIR="/usr/portage/distfiles"
EMERGE_DEFAULT_OPTS="--with-bdeps=y"
FEATURES="assume-digests distlocks fixlafiles fixpackages news parallel-fetch preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch usersandbox usersync"
GENTOO_MIRRORS="http://mirror.rit.edu/gentoo http://mirror.tjhsst.edu/gentoo http://www.gtlib.gatech.edu/pub/gentoo"
LANG="en_US.UTF8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
LINGUAS="en_US en"
MAKEOPTS="-j4"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/var/lib/layman/gamerlay /var/lib/layman/kde /var/lib/layman/sunrise /var/lib/layman/qting-edge /var/lib/layman/x11 /usr/local/portage/overlay"
SYNC="rsync://rsync.namerica.gentoo.org/gentoo-portage"
USE="3dnow X a52 acl acpi aim alsa amd64 bash-completion berkdb branding bzip2 cairo cdaudio cdda cddb cdr clamav cli consolekit cracklib crypt css cups cxx dbus dga dri dvd dvdr encode exif fbcon ffmpeg firefox flac fortran gd gdbm gif gnutls gpm gstreamer hal handbook hddtemp iconv icu id3tag ieee1394 imagemagick ipod ipv6 java java6 jpeg kde lame latex lcms libnotify logrotate mad mmx mng modules mp3 mp4 mpeg mplayer mtp mudflap multilib mysql ncurses networkmanager nls nptl nptlonly nsplugin nvidia offensive ogg openal opengl openmp oscar pam pcre pdf perl phonon plasma png policykit pppd python qt3support qt4 radius readline reflection rss samba scanner sdl semantic-desktop session spell spl sqlite sse sse2 ssl startup-notification svg sysfs taglib tcpd theora threads tiff tk truetype udev unicode usb v4l v4l2 videos vim-syntax vorbis wifi xcb xcomposite xinerama xml xorg xscreensaver xvmc zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" ELIBC="glibc" INPUT_DEVICES="mouse keyboard evdev synaptics elographics" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en_US en" RUBY_TARGETS="ruby18" USERLAND="GNU" VIDEO_CARDS="nouveau nvidia vga v4l" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account" 
Unset:  CPPFLAGS, CTARGET, FFLAGS, INSTALL_MASK, LC_ALL, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 Zac Medico gentoo-dev 2010-08-27 02:40:21 UTC
The problem is that there's some code which implements optional arguments so that you can do things like EMERGE_DEFAULT_OPTS="--keep-going" in make.conf and then disable it on the command line with --keep-going=n. Similarly, --deep supports optional numeric options so that you can control the level of depth. I think it would be nice implement the abbreviation behavior that you like, as long as we can keep the optional argument behavior.
Comment 2 Zac Medico gentoo-dev 2010-09-07 15:18:16 UTC
*** Bug 336333 has been marked as a duplicate of this bug. ***