libgocryptfs/gocryptfs
Jakob Unterwurzacher 552c32c5e9 Move main binary to gocryptfs_main
That way the wrapper shell script can be named just "gocryptfs"
2015-10-05 20:32:10 +02:00

23 lines
409 B
Bash
Executable File

#!/bin/bash
# Simple wrapper that runs the gocryptfs process in the background
set -eu
dir=$(dirname "$0")
main="$dir/gocryptfs_main/gocryptfs_main"
if [ ! -x $main ]; then
echo "Error: gocryptfs_main executable not found. Run ./all.bash to build it."
exit 1
fi
# This needs user input and cannot run in the background
if [[ $* == *--init* ]]; then
"$main" $*
else
"$main" $* &
sleep 0.1
disown
fi