linux-qubasis

linux oasis port as a qubes template

git clone https://9o.is/git/linux-qubasis.git

mount.swap

(379B)


      1 #!/bin/sh
      2 
      3 usage() {
      4     printf 'Usage: %s <fsname>\n' $0
      5     exit 1
      6 }
      7 
      8 if [ $# -eq 0 ]; then
      9     printf '%s: missing arguments\n' $0
     10     usage
     11 fi
     12 
     13 while getopts "o:" opt; do
     14     case $opt in
     15 	o) ;; # not handled for now
     16 	*) usage;;
     17     esac
     18 done
     19 
     20 shift $((OPTIND - 1))
     21 
     22 fsname=$1
     23 
     24 if [ ! -e $fsname ]; then
     25     printf '%s: %s not found' $0 $fsname
     26     exit 1
     27 fi
     28 
     29 swapon $fsname