Created
May 2, 2011 04:36
-
-
Save koko-u/951181 to your computer and use it in GitHub Desktop.
pogoplugでファイルをmount / umount
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
mountpoint=/mnt/pogoplug | |
# find the current state of pogoplug | |
state=`pgrep pogoplugfs` | |
# if off, turn on, else off. | |
if [ "$state" = "" ]; then | |
pogoplugfs --user <email-address> --password <pogoplug_password> --mountpoint $mountpoint > /dev/null 2>&1 & | |
else | |
echo <sudo_password> | sudo -S umount $mountpoint | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment