Skip to content

Instantly share code, notes, and snippets.

@pschichtel
Created October 24, 2012 16:44
Show Gist options
  • Save pschichtel/3947249 to your computer and use it in GitHub Desktop.
Save pschichtel/3947249 to your computer and use it in GitHub Desktop.
#!/bin/sh
cd /dev
for i in `ls sd??`
do
echo "Mounting $i..."
mkdir /mnt/$i 2>/dev/null
if (mount /dev/$i /mnt/$i)
then
echo "succeeded!\n"
else
rmdir /mnt/$i
echo "failed!\n"
fi
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment