1 |
robbat2 08/12/05 20:03:52 |
2 |
|
3 |
Added: |
4 |
python-updater-r133-custom-package-manager-command.patch |
5 |
Log: |
6 |
Bug #249891 - Add support for just calling another binary with the identical syntax to the package manager. Infra-requested feature, commit acked by hawking@g.o. |
7 |
(Portage version: 2.2_rc16/cvs/Linux 2.6.28-rc5-00117-g7f0f598 x86_64) |
8 |
|
9 |
Revision Changes Path |
10 |
1.1 app-admin/python-updater/files/python-updater-r133-custom-package-manager-command.patch |
11 |
|
12 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-admin/python-updater/files/python-updater-r133-custom-package-manager-command.patch?rev=1.1&view=markup |
13 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-admin/python-updater/files/python-updater-r133-custom-package-manager-command.patch?rev=1.1&content-type=text/plain |
14 |
|
15 |
Index: python-updater-r133-custom-package-manager-command.patch |
16 |
=================================================================== |
17 |
------------------------------------------------------------------------ |
18 |
r134 | robbat2 | 2008-12-05 11:58:43 -0800 (Fri, 05 Dec 2008) | 1 line |
19 |
|
20 |
Bug #249891 - Add support for just calling another binary with the identical |
21 |
syntax to the package manager. Infra-requested feature, commit acked by |
22 |
hawking@g.o. |
23 |
------------------------------------------------------------------------ |
24 |
Index: python-updater |
25 |
=================================================================== |
26 |
--- python-updater (revision 133) |
27 |
+++ python-updater (revision 134) |
28 |
@@ -39,6 +39,7 @@ |
29 |
SUPPORTED_PMS="portage pkgcore paludis" |
30 |
PMS_COMMAND=( "emerge" "pmerge" "paludis" ) |
31 |
PMS_OPTIONS=( "-vD1" "-Do" "-i1" ) |
32 |
+CUSTOM_PMS_COMMAND="" |
33 |
|
34 |
# Checks |
35 |
CHECK_ECLASS=0 |
36 |
@@ -86,6 +87,9 @@ |
37 |
-c CMD, --command CMD |
38 |
Pipe found packages to command CMD instead of invoking package |
39 |
manager. Only for debug and script use. |
40 |
+ --package-manager-command CMD |
41 |
+ Call CMD instead of the default command for the specified |
42 |
+ package manager. |
43 |
-eCHECK --enable-CHECK |
44 |
Enable CHECK where CHECK can be one of: |
45 |
* eclass (Disabled by default) |
46 |
@@ -220,6 +224,10 @@ |
47 |
PMS_INDEX=$((${PMS_INDEX} + 1)) |
48 |
done |
49 |
;; |
50 |
+ --package-manager-command) |
51 |
+ shift |
52 |
+ CUSTOM_PMS_COMMAND="$1" |
53 |
+ ;; |
54 |
-c|--command) |
55 |
shift |
56 |
PIPE_COMMAND="$1" |
57 |
@@ -429,7 +437,9 @@ |
58 |
|
59 |
# (Pretend to) remerge packages |
60 |
if [[ -n "${PKGS_TO_REMERGE}" ]]; then |
61 |
- cmd="${PMS_COMMAND[${PMS_INDEX}]} ${PMS_OPTIONS[${PMS_INDEX}]} ${PKGS_TO_REMERGE}" |
62 |
+ pmscmd="${CUSTOM_PMS_COMMAND}" |
63 |
+ [ -z "${pmscmd}" ] && pmscmd="${PMS_COMMAND[${PMS_INDEX}]}" |
64 |
+ cmd="${pmscmd} ${PMS_OPTIONS[${PMS_INDEX}]} ${PKGS_TO_REMERGE}" |
65 |
einfo ${cmd} |
66 |
${cmd} |
67 |
else |