diff --git a/all/lang/go b/all/lang/go new file mode 100644 index 0000000..60e8ad8 --- /dev/null +++ b/all/lang/go @@ -0,0 +1,8 @@ + + +# --- Go Language Environment BEGIN --- +export GOROOT=/opt/go + export PATH=$PATH:/opt/go/bin + export GOPATH=/opt/go/apps + export PATH=$PATH:/opt/go/apps/bin +# --- Go Language Environment END --- diff --git a/all/modules/bind-mount/bind-mount.sh b/all/modules/bind-mount/bind-mount.sh new file mode 100755 index 0000000..ad163fe --- /dev/null +++ b/all/modules/bind-mount/bind-mount.sh @@ -0,0 +1,24 @@ +#!/bin/bash +# must have fuser and bindfs installed +function bmount () { + if [ "$1" == "-mp" ]; then + MOUNTED=$(mountpoint "$2" | grep not) + if [ -z "$MOUNTED" ]; then + echo $2 is a mount point so bind mounting $2/$3 to $4 + notify-send "bind mounting ${2}/${3} to ${4}" --icon=dialog-information -t 2000 + bindfs "$2/$3" "$4" + else + notify-send "${2} not a mount point - Unable to bind mount ${2}/${3} to ${4}" --icon=dialog-error -t 2000 + fi + else + echo bind mounting $1 to $2 + notify-send "bind mounting ${1} to ${2}" --icon=dialog-information -t 2000 + bindfs "$1" "$2" + fi +} + +bumount () { + echo "removing bind mount at $1" + notify-send "removing bind mount at ${1}" --icon=dialog-information -t 2000 + fusermount -u "$1" +}