Browse Source
uswsusp almost completely duplicates resume; merge them. Signed-off-by: Andrey Borzenkov <arvidjaar@gmail.com>master


8 changed files with 51 additions and 58 deletions
@ -1,5 +0,0 @@ |
|||||||
#!/bin/sh |
|
||||||
# -*- mode: shell-script; indent-tabs-mode: nil; sh-basic-offset: 4; -*- |
|
||||||
# ex: ts=8 sw=4 sts=4 et filetype=sh |
|
||||||
|
|
||||||
[ -x /usr/sbin/resume ] || [ -x /usr/lib/suspend/resume ] |
|
@ -1,14 +0,0 @@ |
|||||||
#!/bin/bash |
|
||||||
# -*- mode: shell-script; indent-tabs-mode: nil; sh-basic-offset: 4; -*- |
|
||||||
# ex: ts=8 sw=4 sts=4 et filetype=sh |
|
||||||
|
|
||||||
for bin in /usr/sbin/resume /usr/lib/suspend/resume |
|
||||||
do |
|
||||||
[ -x "${bin}" ] && break |
|
||||||
done |
|
||||||
|
|
||||||
inst "${bin}" /usr/sbin/resume |
|
||||||
[ -f /etc/suspend.conf ] && inst /etc/suspend.conf |
|
||||||
|
|
||||||
inst_hook cmdline 10 "$moddir/parse-uswsusp.sh" |
|
||||||
inst_hook mount 10 "$moddir/resume-uswsusp.sh" |
|
@ -1,23 +0,0 @@ |
|||||||
#!/bin/sh |
|
||||||
# -*- mode: shell-script; indent-tabs-mode: nil; sh-basic-offset: 4; -*- |
|
||||||
# ex: ts=8 sw=4 sts=4 et filetype=sh |
|
||||||
|
|
||||||
if resume=$(getarg resume=) && ! getarg noresume; then |
|
||||||
export resume |
|
||||||
else |
|
||||||
unset resume |
|
||||||
fi |
|
||||||
|
|
||||||
case "$resume" in |
|
||||||
LABEL=*) \ |
|
||||||
resume="$(echo $resume | sed 's,/,\\x2f,g')" |
|
||||||
resume="/dev/disk/by-label/${resume#LABEL=}" ;; |
|
||||||
UUID=*) \ |
|
||||||
resume="/dev/disk/by-uuid/${resume#UUID=}" ;; |
|
||||||
esac |
|
||||||
|
|
||||||
if splash=$(getarg rd.splash= splash=); then |
|
||||||
export splash |
|
||||||
else |
|
||||||
unset splash |
|
||||||
fi |
|
@ -1,16 +0,0 @@ |
|||||||
#!/bin/sh |
|
||||||
# -*- mode: shell-script; indent-tabs-mode: nil; sh-basic-offset: 4; -*- |
|
||||||
# ex: ts=8 sw=4 sts=4 et filetype=sh |
|
||||||
|
|
||||||
case "$splash" in |
|
||||||
quiet ) |
|
||||||
a_splash="-P splash=y" |
|
||||||
;; |
|
||||||
* ) |
|
||||||
a_splash="-P splash=n" |
|
||||||
;; |
|
||||||
esac |
|
||||||
|
|
||||||
if [ -n "$resume" ]; then |
|
||||||
/usr/sbin/resume $a_splash "$resume" |
|
||||||
fi |
|
Loading…
Reference in new issue