1 |
commit: a5c0c7a1c5610f8040ea1fdb1d0a1f8c4d2f45b3 |
2 |
Author: Louis Sautier <sautier.louis <AT> gmail <DOT> com> |
3 |
AuthorDate: Mon Feb 15 00:15:46 2016 +0000 |
4 |
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Mar 2 18:06:51 2018 +0000 |
6 |
URL: https://gitweb.gentoo.org/proj/gentoo-bashcomp.git/commit/?id=a5c0c7a1 |
7 |
|
8 |
add completion for emerge --rage-clean |
9 |
|
10 |
This PR adds the --rage-clean option. |
11 |
|
12 |
Closes: https://github.com/gentoo/gentoo-bashcomp/pull/2 |
13 |
|
14 |
completions/emerge | 6 +++--- |
15 |
1 file changed, 3 insertions(+), 3 deletions(-) |
16 |
|
17 |
diff --git a/completions/emerge b/completions/emerge |
18 |
index a7d1f52..d7da227 100644 |
19 |
--- a/completions/emerge |
20 |
+++ b/completions/emerge |
21 |
@@ -29,7 +29,7 @@ _emerge() |
22 |
# find action |
23 |
for x in ${COMP_LINE} ; do |
24 |
if [[ ${x} =~ ^(system|world)$ ]] || [[ ${x} =~ -[CPcs] ]] || \ |
25 |
- [[ ${x} =~ --(clean|config|depclean|info|metadata|prune|regen|resume|search|sync|unmerge) ]] |
26 |
+ [[ ${x} =~ --(clean|config|depclean|info|metadata|prune|rage-clean|regen|resume|search|sync|unmerge) ]] |
27 |
then |
28 |
action=${x} |
29 |
break |
30 |
@@ -101,7 +101,7 @@ _emerge() |
31 |
--newuse --noconfmem --nodeps --noreplace --nospinner \ |
32 |
--oneshot --onlydeps \ |
33 |
--pretend --prune \ |
34 |
- --quiet \ |
35 |
+ --quiet --rage-clean \ |
36 |
--reinstall=changed-use --regen \ |
37 |
--search \ |
38 |
--sync \ |
39 |
@@ -153,7 +153,7 @@ _emerge() |
40 |
fi |
41 |
|
42 |
# Complete on installed packages when unmerging. |
43 |
- if [[ "${action}" == '--unmerge' ]]; then |
44 |
+ if [[ "${action}" =~ --(rage-clean|unmerge) ]]; then |
45 |
if [[ -n "${cur}" ]] ; then |
46 |
if [[ "${cur}" == */* ]]; then |
47 |
words=$(builtin cd @GENTOO_PORTAGE_EPREFIX@/var/db/pkg; compgen -G "${cur}*") |