Browse Source

send stderr from which to /dev/null too

tags/2.72
Joey Hess 13 years ago
parent
commit
e98a704973
2 changed files with 3 additions and 3 deletions
  1. +2
    -2
      tests/desktop
  2. +1
    -1
      tests/laptop

+ 2
- 2
tests/desktop View File

@@ -69,7 +69,7 @@ enough_disk () {
}

desktop_hardware () {
if which laptop-detect >/dev/null && \
if which laptop-detect >/dev/null 2>&1 && \
laptop-detect; then
# Nearly always appropriate to include a desktop.
return 0
@@ -83,7 +83,7 @@ desktop_hardware () {
}

rack_hardware () {
if which dmidecode >/dev/null && \
if which dmidecode >/dev/null 2>&1 && \
dmidecode | grep -q 'Type: Rack Mount Chassis'; then
return 0
fi


+ 1
- 1
tests/laptop View File

@@ -2,7 +2,7 @@
# Causes a task to be selected if the machine appears to be a laptop.

if [ "$NEW_INSTALL" ]; then
if which laptop-detect >/dev/null && \
if which laptop-detect >/dev/null 2>&1 && \
laptop-detect; then
exit 2 # mark for install
else


Loading…
Cancel
Save