Last change
on this file since 2942 was
2941,
checked in by broder, 15 years ago
|
Add code to invirt-reload to de-duplicate multiple invocations. (LP: #439426)
This uses the dpkg triggers mechanism to de-duplicate multiple
invocations of invirt-reload over the course of a single dpkg run.
The code is largely lifted from Ubuntu's update-initramfs.
|
-
Property svn:executable set to
*
|
File size:
449 bytes
|
Line | |
---|
1 | #!/bin/bash |
---|
2 | |
---|
3 | if [ "$DPKG_MAINTSCRIPT_PACKAGE" != '' ] && \ |
---|
4 | [ $# = 0 ] && \ |
---|
5 | dpkg-trigger --check-supported 2>/dev/null; then |
---|
6 | if dpkg-trigger --no-await invirt-base; then |
---|
7 | echo "invirt-reload: deferring update (trigger activated)" |
---|
8 | exit 0 |
---|
9 | fi |
---|
10 | fi |
---|
11 | |
---|
12 | for script in $(run-parts --test /etc/init.d); do |
---|
13 | if [ "${script#/etc/init.d/invirt-}" != "$script" ]; then |
---|
14 | invoke-rc.d "${script#/etc/init.d/}" force-reload |
---|
15 | fi |
---|
16 | done |
---|
Note: See
TracBrowser
for help on using the repository browser.