14 lines
307 B
Bash
14 lines
307 B
Bash
|
#!/bin/bash
|
||
|
|
||
|
case "$2" in
|
||
|
available)
|
||
|
echo $(/bin/df | /bin/grep "$1"| /usr/bin/awk '{print $4}')
|
||
|
;;
|
||
|
usage)
|
||
|
echo $(/bin/df | /bin/grep "$1"| /usr/bin/awk '{print $3}')
|
||
|
;;
|
||
|
percent)
|
||
|
echo $(/bin/df | /bin/grep "$1"| /usr/bin/awk '{print $5}' | tr -d "%")
|
||
|
;;
|
||
|
esac
|