File: script

package info (click to toggle)
grub 0.97-84
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 7,240 kB
  • sloc: ansic: 40,100; sh: 5,393; asm: 2,227; makefile: 479; perl: 338
file content (28 lines) | stat: -rwxr-xr-x 628 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#!/bin/bash
set -e

for i in /boot/grub/device.map ; do
  if test -e $i ; then
    echo -e "\n*********************** BEGIN $i" >&3
    cat $i >&3
    echo "*********************** END $i" >&3
  fi
done

for i in /proc/mounts ; do
  if test -e $i ; then
    echo -e "\n*********************** BEGIN $i" >&3
    grep ^/dev/ $i >&3
    echo "*********************** END $i" >&3
  fi
done

for i in /boot/grub/menu.lst ; do
  if test -e $i ; then
    echo -e "\n*********************** BEGIN $i" >&3
    sed $i -e "s/.*password.*/### PASSWORD LINE REMOVED ###/g" >&3
    echo "*********************** END $i" >&3
  fi
done

exit 0