Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 395091 - [tracker] app-shells/bash-completion-2.1 version bump
Summary: [tracker] app-shells/bash-completion-2.1 version bump
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: Normal enhancement (vote)
Assignee: Gentoo Shell Tools project
URL: http://bash-completion.alioth.debian....
Whiteboard:
Keywords: InVCS, Tracker
: 423419 476270 (view as bug list)
Depends on: 472250 472844
Blocks: 465094
  Show dependency tree
 
Reported: 2011-12-17 18:28 UTC by Raphaël Droz
Modified: 2014-08-02 20:39 UTC (History)
9 users (show)

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


Attachments
ebuild for bash-completion-1.90 (bash-completion-1.90.ebuild,1.35 KB, text/plain)
2011-12-17 18:29 UTC, Raphaël Droz
Details
See http://bugs.gentoo.org/472938 for files (file_395091.txt,55 bytes, text/plain)
2013-06-13 06:28 UTC, Samuli Suominen (RETIRED)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Raphaël Droz 2011-12-17 18:28:29 UTC
This is a beta release (pre-2.0) and a very good opportunity to remove Gentoo compatibility wrappers (for loading) [in the same way upstream dropped support for bash < 4.1]

- the test-suite should be supported (but it stills fails for the moment).
- sys-apps/miscfiles dependency has been dropped : it's only needed for dict(1) completion. So a "bash-completion" useflag for the ebuild(s) providing dict(1) (like app-text/dictd) is more suited for this
- support for zsh has been dropped from the ebuild (until someone is willing to test it)
- some typos in postinst() have been fixed


Reproducible: Always
Comment 1 Raphaël Droz 2011-12-17 18:29:15 UTC
Created attachment 296147 [details]
ebuild for bash-completion-1.90
Comment 2 Raphaël Droz 2011-12-17 18:31:11 UTC
Rereading the post-installation message, we may even replace
> elog ".bashrc by running:"
by
> elog "~/.bash_completion.d directory by running:"
Comment 3 Mike Gilbert gentoo-dev 2011-12-17 22:41:51 UTC
Please provide a patch when modifying ebuilds for existing packages.
Comment 4 Jeremy Olexa (darkside) (RETIRED) archtester gentoo-dev Security 2011-12-19 15:00:33 UTC
Hi there. 

* Why do you completely drop the wrapper? Specifically, what is your migration strategy with regards to .pre, base, .post?
Comment 5 Raphaël Droz 2012-04-07 19:22:12 UTC
AFAICT upstream 1.9x takes into account :
* dynamic completion loading (so most of the current completion symlinks may be dropped)
* user disabling unconditionnal system completions (shopt in ~/.bash_completion) [1] and defining some configuration (COMP_* variables)
* user enabling unconditionnal custom completion using `export BASH_COMPLETION_COMPAT_DIR=$HOME/.bash_completion.d` (but I don't know if there are other recommanded solutions)
* system-wide unconditionnal completion loading using BASH_COMPLETION_COMPAT_DIR
* user doing any other random stuff : ~/.bash_completion

So the only directory for which some gentoo tweaks may be needed is ~/.bash_completion.d/*, but it would 1) only avoid a trivial configuration addition, useless for most users and 2) not be really important since completions are now dynamically loaded.

I don't really thought about a migration strategy but most of it would be related to the eselect bashcomp module because the only sad thing I can think about with the new release is to have a bunch of completion being forgotten /etc/bash_completion.d and ~/.bash_completion.d thus cancelling the main benefit of dynamic completion loading.


[1] or rather ${XDG_CONFIG_HOME:-$HOME/.config}/bash_completion
Comment 6 Michael Palimaka (kensington) gentoo-dev 2012-06-25 17:11:14 UTC
*** Bug 423419 has been marked as a duplicate of this bug. ***
Comment 7 Alexander Tsoy 2013-04-12 16:40:27 UTC
1. bash-completion-2.1 was released

2. We definetly need >=bash-completion-2.0. Some modern software tries to use pkg-config to get a directory to store bash completions. If no bash-completion.pc is found (this is true for bash-completion-1.3), then they fall back to /usr/share/bash-completion/completions, and such completions can't be selected via "eselect bashcomp".

# qfile -qC /usr/share/bash-completion/completions
sys-apps/systemd
sys-kernel/dracut

also see:
bug 465094
bug 465100



This is from systemd's configure script:

# Check whether --with-bashcompletiondir was given.
if test "${with_bashcompletiondir+set}" = set; then :
  withval=$with_bashcompletiondir;
else
  if $($PKG_CONFIG --exists bash-completion); then :

                with_bashcompletiondir=$($PKG_CONFIG --variable=completionsdir bash-completion)

else

                with_bashcompletiondir=${datadir}/bash-completion/completions

fi
fi
Comment 8 Alexander Tsoy 2013-04-12 16:48:28 UTC
Sorry, bash-completion.pc was already backported.

*bash-completion-1.3-r1 (01 Nov 2012)

  01 Nov 2012; Samuli Suominen <ssuominen@gentoo.org>
  +bash-completion-1.3-r1.ebuild, +files/bash-completion.pc:
  Backport modified bash-completion.pc pkg-config file from upstream 2.0
  release.
Comment 9 Jeroen Roovers (RETIRED) gentoo-dev 2013-06-03 22:31:40 UTC
Bumped to 2.1. I am not seeing any problems here except with stale files left in some users' ~/.bash_completion.d/ . Maybe leave this open for a bit to catch problems?
Comment 10 Greg Kubaryk 2013-06-04 00:08:43 UTC
(In reply to Jeroen Roovers from comment #9)
> Bumped to 2.1. I am not seeing any problems here except with stale files
> left in some users' ~/.bash_completion.d/ . Maybe leave this open for a bit
> to catch problems?

Attempting to upgrade on ~amd64 just now:

 * Detected file collision(s):
 * 
 * 	/usr/share/bash-completion/ionice
 * 	/usr/share/bash-completion/hwclock
 * 	/usr/share/bash-completion/renice
 * 	/usr/share/bash-completion/eject
 * 	/usr/share/bash-completion/look
 * 	/usr/share/bash-completion/cal
 * 	/usr/share/bash-completion/hexdump
 * 	/usr/share/bash-completion/dmesg
 * 
 * Searching all installed packages for file collisions...
 * 
 * Press Ctrl-C to Stop
 * 
 * sys-apps/util-linux-2.23:0::gentoo
 * 	/usr/share/bash-completion/cal
 * 	/usr/share/bash-completion/dmesg
 * 	/usr/share/bash-completion/eject
 * 	/usr/share/bash-completion/hexdump
 * 	/usr/share/bash-completion/hwclock
 * 	/usr/share/bash-completion/ionice
 * 	/usr/share/bash-completion/look
 * 	/usr/share/bash-completion/renice

If additional information is necessary, please let me know and I'd be happy to provide it.
Comment 11 Jeroen Roovers (RETIRED) gentoo-dev 2013-06-04 01:56:04 UTC
(In reply to Greg Kubaryk from comment #10)
> (In reply to Jeroen Roovers from comment #9)
> > Bumped to 2.1. I am not seeing any problems here except with stale files
> > left in some users' ~/.bash_completion.d/ . Maybe leave this open for a bit
> > to catch problems?
> 
> Attempting to upgrade on ~amd64 just now:
> 
>  * Detected file collision(s):
>  * 
>  * 	/usr/share/bash-completion/ionice
>  * 	/usr/share/bash-completion/hwclock
>  * 	/usr/share/bash-completion/renice
>  * 	/usr/share/bash-completion/eject
>  * 	/usr/share/bash-completion/look
>  * 	/usr/share/bash-completion/cal
>  * 	/usr/share/bash-completion/hexdump
>  * 	/usr/share/bash-completion/dmesg
>  * 
>  * Searching all installed packages for file collisions...
>  * 
>  * Press Ctrl-C to Stop
>  * 
>  * sys-apps/util-linux-2.23:0::gentoo
>  * 	/usr/share/bash-completion/cal
>  * 	/usr/share/bash-completion/dmesg
>  * 	/usr/share/bash-completion/eject
>  * 	/usr/share/bash-completion/hexdump
>  * 	/usr/share/bash-completion/hwclock
>  * 	/usr/share/bash-completion/ionice
>  * 	/usr/share/bash-completion/look
>  * 	/usr/share/bash-completion/renice
> 
> If additional information is necessary, please let me know and I'd be happy
> to provide it.

That should have been fixed with bug #468544 which explicitly removes the rtcwake completion in the bash-completion ebuild but leaves other files in place. It's fixed now, though.
Comment 12 Greg Kubaryk 2013-06-04 03:05:28 UTC
(In reply to Jeroen Roovers from comment #11)
> It's fixed now, though.

Sure is.  Thanks.

Looks like #472250 may be duplicate.  I guess we messed up by conflating two issues in one bug, but hey, it's fixed now.
Comment 13 Ryan Hill (RETIRED) gentoo-dev 2013-06-04 03:37:41 UTC
Uh, how are you planning on addressing the whole migration strategy and wrapper setup?  That's what was holding this bug back.
Comment 14 Jeroen Roovers (RETIRED) gentoo-dev 2013-06-04 13:14:55 UTC
(In reply to Ryan Hill from comment #13)
> Uh, how are you planning on addressing the whole migration strategy and
> wrapper setup?  That's what was holding this bug back.

That's what comment #3 is about? What is holding us back, then?
Comment 15 Jeroen Roovers (RETIRED) gentoo-dev 2013-06-04 13:15:24 UTC
Comment #4 I meant.
Comment 16 Jeroen Roovers (RETIRED) gentoo-dev 2013-06-04 13:46:46 UTC
If there are outstanding issues, they should be reported as separate bugs that block this one.
Comment 17 Alexander Tsoy 2013-06-04 15:45:32 UTC
Two questions.

1. Why we need the wrapper and eselect module with bash-completion-2? I always thought that they need to solve performance problems (in bash-completion-1 all modules are loaded at once). Loading modules on demand is supported since bash-completion 1.90 (2.0 preview).

2. Why we still use non-standard directory for completions? Upstream and all modern distributions are using "/usr/share/bash-completion/completions". Most packages installs completions in this directory by default. Several ebuilds currently change this path to "/usr/share/bash-completion" using sed, and many ebuilds simply do something like this at install phase:

rm -rf "${ED}"/usr/share/bash-completion
dobashcomp path/to/bashcomp


Is there a plan to address this issues?
Comment 18 Ryan Hill (RETIRED) gentoo-dev 2013-06-05 02:51:27 UTC
We shouldn't need the eselect module now IIUC.  I haven't looked into how exactly dynamic loading works.  I keep meaning to but, you know...

Alexander/Raphaël, is anything broken by this version bump?  If not then I say we leave it as is and file a couple enhancement bugs to deprecate the eselect module and migrate the install path.
Comment 19 Samuli Suominen (RETIRED) gentoo-dev 2013-06-13 06:28:57 UTC
Created attachment 350866 [details]
See http://bugs.gentoo.org/472938 for files

Files at bug 472938
Comment 20 Jeroen Roovers (RETIRED) gentoo-dev 2013-07-10 11:01:32 UTC
*** Bug 476270 has been marked as a duplicate of this bug. ***
Comment 21 Evgeny Bobkin 2013-07-10 11:14:38 UTC
What is the point to close #476270 as duplicate instead of making dependent on this one?
Comment 22 Samuli Suominen (RETIRED) gentoo-dev 2013-07-16 00:14:27 UTC
(In reply to Evgeny Bobkin from comment #21)
> What is the point to close #476270 as duplicate instead of making dependent
> on this one?

because this one solves that one directly

2.1-r1 in tree, closing
Comment 23 Jeroen Roovers (RETIRED) gentoo-dev 2013-07-16 13:07:13 UTC
*** Bug 476270 has been marked as a duplicate of this bug. ***